{"thread":{"id":"54123","subject":"[PATCH 1/2] Unify `update-index --cacheinfo` usage","startedAt":"2020-08-24T14:51:59Z","lastAt":"2020-08-24T18:51:47Z","messageCount":4,"participants":["Vadim Sannikov via GitGitGadget","Junio C Hamano"],"isPatch":true,"patchVersion":1,"patchTotal":2},"messages":[{"id":"404317","messageId":"fc2138e1db2de46793100b87c00dbde270f6b350.1598280704.git.gitgitgadget@gmail.com","threadId":"54123","inReplyTo":"pull.708.git.1598280703.gitgitgadget@gmail.com","subject":"[PATCH 1/2] Unify `update-index --cacheinfo` usage","fromName":"Vadim Sannikov via GitGitGadget","fromEmail":"gitgitgadget@gmail.com","sentAt":"2020-08-24T14:51:42Z","receivedAt":"2020-08-24T14:51:59Z","isPatch":true,"sender":{"key":"name:Vadim Sannikov","avatar":null},"body":"From: Vadim Sannikov <vsj.vadim@gmail.com>\n\nThe old three separate parameters format (`<mode> <object> <path>`)\nis replaced with the modern, single-parameter form\n(`<mode>,<object>,<path>`).\n\nDifferent parts of Git code use different syntax, so the commit unifies\nit. According to `git-update-index` manual page, the new form is\npreferred.\n\nSigned-off-by: Vadim Sannikov <vsj.vadim@gmail.com>\n---\n git-merge-one-file.sh | 6 +++---\n git-mergetool.sh      | 2 +-\n merge-recursive.c     | 2 +-\n po/bg.po              | 4 ++--\n po/ca.po              | 4 ++--\n po/de.po              | 4 ++--\n po/el.po              | 2 +-\n po/es.po              | 4 ++--\n po/fr.po              | 4 ++--\n po/git.pot            | 2 +-\n po/it.po              | 4 ++--\n po/ko.po              | 4 ++--\n po/ru.po              | 8 ++++++--\n po/sv.po              | 4 ++--\n po/tr.po              | 4 ++--\n po/vi.po              | 4 ++--\n po/zh_CN.po           | 4 ++--\n po/zh_TW.po           | 4 ++--\n 18 files changed, 37 insertions(+), 33 deletions(-)\n\ndiff --git a/git-merge-one-file.sh b/git-merge-one-file.sh\nindex f6d9852d2f..5691c4e7ff 100755\n--- a/git-merge-one-file.sh\n+++ b/git-merge-one-file.sh\n@@ -71,7 +71,7 @@ case \"${1:-.}${2:-.}${3:-.}\" in\n \".$2.\")\n \t# the other side did not add and we added so there is nothing\n \t# to be done, except making the path merged.\n-\texec git update-index --add --cacheinfo \"$6\" \"$2\" \"$4\"\n+\texec git update-index --add --cacheinfo \"$6\",\"$2\",\"$4\"\n \t;;\n \"..$3\")\n \techo \"Adding $4\"\n@@ -80,7 +80,7 @@ case \"${1:-.}${2:-.}${3:-.}\" in\n \t\techo \"ERROR: untracked $4 is overwritten by the merge.\" >&2\n \t\texit 1\n \tfi\n-\tgit update-index --add --cacheinfo \"$7\" \"$3\" \"$4\" &&\n+\tgit update-index --add --cacheinfo \"$7\",\"$3\",\"$4\" &&\n \t\texec git checkout-index -u -f -- \"$4\"\n \t;;\n \n@@ -95,7 +95,7 @@ case \"${1:-.}${2:-.}${3:-.}\" in\n \t\texit 1\n \tfi\n \techo \"Adding $4\"\n-\tgit update-index --add --cacheinfo \"$6\" \"$2\" \"$4\" &&\n+\tgit update-index --add --cacheinfo \"$6\",\"$2\",\"$4\" &&\n \t\texec git checkout-index -u -f -- \"$4\"\n \t;;\n \ndiff --git a/git-mergetool.sh b/git-mergetool.sh\nindex e3f6d543fb..ad37b15f4b 100755\n--- a/git-mergetool.sh\n+++ b/git-mergetool.sh\n@@ -224,7 +224,7 @@ stage_submodule () {\n \t)\n \ttest -n \"$work_rel_path\" ||\n \tdie \"fatal: unable to get path of module $path relative to work tree\"\n-\tgit update-index --add --replace --cacheinfo 160000 \"$submodule_sha1\" \"${work_rel_path%/}\" || die\n+\tgit update-index --add --replace --cacheinfo 160000,\"$submodule_sha1\",\"${work_rel_path%/}\" || die\n }\n \n checkout_staged_file () {\ndiff --git a/merge-recursive.c b/merge-recursive.c\nindex d0214335a7..dfe6f67ec8 100644\n--- a/merge-recursive.c\n+++ b/merge-recursive.c\n@@ -1259,7 +1259,7 @@ static int merge_submodule(struct merge_options *opt,\n \t\t       \"If this is correct simply add it to the index \"\n \t\t       \"for example\\n\"\n \t\t       \"by using:\\n\\n\"\n-\t\t       \"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\\n\"\n+\t\t       \"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\\n\"\n \t\t       \"which will accept this suggestion.\\n\"),\n \t\t       oid_to_hex(&merges.objects[0].item->oid), path);\n \t\tbreak;\ndiff --git a/po/bg.po b/po/bg.po\nindex a189b16dc4..517c0e6b49 100644\n--- a/po/bg.po\n+++ b/po/bg.po\n@@ -4737,13 +4737,13 @@ msgid \"\"\n \"If this is correct simply add it to the index for example\\n\"\n \"by using:\\n\"\n \"\\n\"\n-\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"which will accept this suggestion.\\n\"\n msgstr \"\"\n \"Ако това е така, добавете го към индекса с команда като следната:\\n\"\n \"\\n\"\n-\"    git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"Това приема предложеното.\\n\"\n \ndiff --git a/po/ca.po b/po/ca.po\nindex c43c21bc22..61c3a7f9b0 100644\n--- a/po/ca.po\n+++ b/po/ca.po\n@@ -4592,12 +4592,12 @@ msgid \"\"\n \"If this is correct simply add it to the index for example\\n\"\n \"by using:\\n\"\n \"\\n\"\n-\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"which will accept this suggestion.\\n\"\n msgstr \"\"\n \"Si això és correcte simplement afegiu-ho a l'índex per exemple utilitzant \"\n-\"git update-index --cacheinfo 160000 per cents \\\"%s\\\" que acceptaran aquest \"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\" que acceptaran aquest \"\n \"suggeriment.\\n\"\n \n #: merge-recursive.c:1268\ndiff --git a/po/de.po b/po/de.po\nindex 656de24218..ec0106f2b8 100644\n--- a/po/de.po\n+++ b/po/de.po\n@@ -4641,14 +4641,14 @@ msgid \"\"\n \"If this is correct simply add it to the index for example\\n\"\n \"by using:\\n\"\n \"\\n\"\n-\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"which will accept this suggestion.\\n\"\n msgstr \"\"\n \"Falls das korrekt ist, fügen Sie es einfach der Staging-Area, zum Beispiel \"\n \"mit:\\n\"\n \"\\n\"\n-\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"hinzu, um diesen Vorschlag zu akzeptieren.\\n\"\n \ndiff --git a/po/el.po b/po/el.po\nindex 703f46d0c7..e775885187 100644\n--- a/po/el.po\n+++ b/po/el.po\n@@ -3075,7 +3075,7 @@ msgid \"\"\n \"If this is correct simply add it to the index for example\\n\"\n \"by using:\\n\"\n \"\\n\"\n-\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"which will accept this suggestion.\\n\"\n msgstr \"\"\ndiff --git a/po/es.po b/po/es.po\nindex 41a72ca6fb..1c1aeebe47 100644\n--- a/po/es.po\n+++ b/po/es.po\n@@ -4572,14 +4572,14 @@ msgid \"\"\n \"If this is correct simply add it to the index for example\\n\"\n \"by using:\\n\"\n \"\\n\"\n-\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"which will accept this suggestion.\\n\"\n msgstr \"\"\n \"Si esto es correcto simplemente agrégalo al índice por ejemplo\\n\"\n \"usando:\\n\"\n \"\\n\"\n-\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"el cual aceptará esta sugerencia.\\n\"\n \ndiff --git a/po/fr.po b/po/fr.po\nindex d20fc440ab..157c41ff4c 100644\n--- a/po/fr.po\n+++ b/po/fr.po\n@@ -4714,14 +4714,14 @@ msgid \"\"\n \"If this is correct simply add it to the index for example\\n\"\n \"by using:\\n\"\n \"\\n\"\n-\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"which will accept this suggestion.\\n\"\n msgstr \"\"\n \"Si c'est correct, ajoutez le simplement à l'index\\n\"\n \"en utilisant par exemple :\\n\"\n \"\\n\"\n-\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"qui acceptera cette suggestion.\\n\"\n \ndiff --git a/po/git.pot b/po/git.pot\nindex 198b6e0a4a..2d50bebf5a 100644\n--- a/po/git.pot\n+++ b/po/git.pot\n@@ -4256,7 +4256,7 @@ msgid \"\"\n \"If this is correct simply add it to the index for example\\n\"\n \"by using:\\n\"\n \"\\n\"\n-\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"which will accept this suggestion.\\n\"\n msgstr \"\"\ndiff --git a/po/it.po b/po/it.po\nindex 53523e76df..c8264dd7bc 100644\n--- a/po/it.po\n+++ b/po/it.po\n@@ -4649,14 +4649,14 @@ msgid \"\"\n \"If this is correct simply add it to the index for example\\n\"\n \"by using:\\n\"\n \"\\n\"\n-\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"which will accept this suggestion.\\n\"\n msgstr \"\"\n \"Se è corretta aggiungila semplicemente all'indice, ad esempio\\n\"\n \"usando:\\n\"\n \"\\n\"\n-\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"per accettare questo suggerimento.\\n\"\n \ndiff --git a/po/ko.po b/po/ko.po\nindex dcfe21c223..47b611edee 100644\n--- a/po/ko.po\n+++ b/po/ko.po\n@@ -2361,14 +2361,14 @@ msgid \"\"\n \"If this is correct simply add it to the index for example\\n\"\n \"by using:\\n\"\n \"\\n\"\n-\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"which will accept this suggestion.\\n\"\n msgstr \"\"\n \"이 제안이 맞으면 인덱스에 추가하면 됩니다. 예를 들어\\n\"\n \"다음 명령을 사용하면:\\n\"\n \"\\n\"\n-\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"제안을 받아들이게 됩니다.\\n\"\n \ndiff --git a/po/ru.po b/po/ru.po\nindex a77b462e62..a928cd879e 100644\n--- a/po/ru.po\n+++ b/po/ru.po\n@@ -3523,10 +3523,14 @@ msgid \"\"\n \"If this is correct simply add it to the index for example\\n\"\n \"by using:\\n\"\n \"\\n\"\n-\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"which will accept this suggestion.\\n\"\n-msgstr \"Если оно верное, то просто добавьте его в индекс, например так:\\n\\n  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\\nтем самым принимая это предположение.\\n\"\n+msgstr \"Если оно верное, то просто добавьте его в индекс, например так:\\n\"\n+\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n+\"\\n\"\n+\"тем самым принимая это предположение.\\n\"\n \n #: merge-recursive.c:1252\n #, c-format\ndiff --git a/po/sv.po b/po/sv.po\nindex 93f3c6f3f7..f5a850f0b7 100644\n--- a/po/sv.po\n+++ b/po/sv.po\n@@ -4551,14 +4551,14 @@ msgid \"\"\n \"If this is correct simply add it to the index for example\\n\"\n \"by using:\\n\"\n \"\\n\"\n-\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"which will accept this suggestion.\\n\"\n msgstr \"\"\n \"Om detta är riktigt lägger du bara till det i indexet, till\\n\"\n \"exempel så här:\\n\"\n \"\\n\"\n-\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"vilket godtar lösningen.\\n\"\n \ndiff --git a/po/tr.po b/po/tr.po\nindex 9a17c19b25..af5f9ba7f8 100644\n--- a/po/tr.po\n+++ b/po/tr.po\n@@ -4619,13 +4619,13 @@ msgid \"\"\n \"If this is correct simply add it to the index for example\\n\"\n \"by using:\\n\"\n \"\\n\"\n-\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"which will accept this suggestion.\\n\"\n msgstr \"\"\n \"Eğer bu doğruysa yalnızca indekse ekleyin, örneğinbu öneriyi kabul edecek:\\n\"\n \"\\n\"\n-\"\\tgit update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"komutunu kullanmanız yeterlidir.\\n\"\n \ndiff --git a/po/vi.po b/po/vi.po\nindex d730cf1141..beec050125 100644\n--- a/po/vi.po\n+++ b/po/vi.po\n@@ -4548,14 +4548,14 @@ msgid \"\"\n \"If this is correct simply add it to the index for example\\n\"\n \"by using:\\n\"\n \"\\n\"\n-\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"which will accept this suggestion.\\n\"\n msgstr \"\"\n \"Nếu đây là đúng đơn giản thêm nó vào mục lục ví dụ\\n\"\n \"bằng cách dùng:\\n\"\n \"\\n\"\n-\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"cái mà sẽ chấp nhận gợi ý này.\\n\"\n \ndiff --git a/po/zh_CN.po b/po/zh_CN.po\nindex a531819623..69dd29140b 100644\n--- a/po/zh_CN.po\n+++ b/po/zh_CN.po\n@@ -4567,13 +4567,13 @@ msgid \"\"\n \"If this is correct simply add it to the index for example\\n\"\n \"by using:\\n\"\n \"\\n\"\n-\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"which will accept this suggestion.\\n\"\n msgstr \"\"\n \"如果这个正确，将其添加到索引，例如使用命令：\\n\"\n \"\\n\"\n-\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"以接受此建议。\\n\"\n \ndiff --git a/po/zh_TW.po b/po/zh_TW.po\nindex 9334b46faa..18e6b8985a 100644\n--- a/po/zh_TW.po\n+++ b/po/zh_TW.po\n@@ -4692,13 +4692,13 @@ msgid \"\"\n \"If this is correct simply add it to the index for example\\n\"\n \"by using:\\n\"\n \"\\n\"\n-\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"which will accept this suggestion.\\n\"\n msgstr \"\"\n \"如果這個正確，將其新增到索引，例如使用指令：\\n\"\n \"\\n\"\n-\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n+\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n \"\\n\"\n \"以接受此建議。\\n\"\n \n-- \ngitgitgadget\n\n"},{"id":"404318","messageId":"pull.708.git.1598280703.gitgitgadget@gmail.com","threadId":"54123","inReplyTo":null,"subject":"[PATCH 0/2] Update update-index --cacheinfo entries' format","fromName":"Vadim Sannikov via GitGitGadget","fromEmail":"gitgitgadget@gmail.com","sentAt":"2020-08-24T14:51:41Z","receivedAt":"2020-08-24T14:52:03Z","isPatch":true,"sender":{"key":"name:Vadim Sannikov","avatar":null},"body":"According to git-update-index manual page:\n\n> --cacheinfo <mode>,<object>,<path>--cacheinfo <mode> <object> <path>\n> Directly insert the specified info into the index. For backward\n> compatibility, you can also give these three arguments as three separate\n> parameters, but new users are encouraged to use a single-parameter form.\n\nSo, my commits change every old-style entry in code to the new format. It's\nnot entirely necessary, but it unifies --cacheinfo usage across the code.\n\nVadim Sannikov (2):\n  Unify `update-index --cacheinfo` usage\n  Unify `update-index --cacheinfo` usage (tests)\n\n git-merge-one-file.sh             |  6 +++---\n git-mergetool.sh                  |  2 +-\n merge-recursive.c                 |  2 +-\n po/bg.po                          |  4 ++--\n po/ca.po                          |  4 ++--\n po/de.po                          |  4 ++--\n po/el.po                          |  2 +-\n po/es.po                          |  4 ++--\n po/fr.po                          |  4 ++--\n po/git.pot                        |  2 +-\n po/it.po                          |  4 ++--\n po/ko.po                          |  4 ++--\n po/ru.po                          |  8 ++++++--\n po/sv.po                          |  4 ++--\n po/tr.po                          |  4 ++--\n po/vi.po                          |  4 ++--\n po/zh_CN.po                       |  4 ++--\n po/zh_TW.po                       |  4 ++--\n t/lib-submodule-update.sh         |  2 +-\n t/t0028-working-tree-encoding.sh  |  4 ++--\n t/t1006-cat-file.sh               |  2 +-\n t/t1010-mktree.sh                 |  2 +-\n t/t1050-large.sh                  |  2 +-\n t/t1450-fsck.sh                   |  4 ++--\n t/t3600-rm.sh                     |  4 ++--\n t/t5520-pull.sh                   |  2 +-\n t/t5526-fetch-submodules.sh       | 18 +++++++++---------\n t/t5531-deep-submodule-push.sh    |  2 +-\n t/t6130-pathspec-noglob.sh        |  2 +-\n t/t6430-merge-recursive.sh        |  2 +-\n t/t7003-filter-branch.sh          |  2 +-\n t/t7011-skip-worktree-reading.sh  |  4 ++--\n t/t7012-skip-worktree-writing.sh  |  4 ++--\n t/t7113-post-index-change-hook.sh |  2 +-\n t/t7406-submodule-update.sh       |  4 ++--\n t/t9350-fast-export.sh            |  8 ++++----\n t/test-lib-functions.sh           |  2 +-\n 37 files changed, 73 insertions(+), 69 deletions(-)\n\n\nbase-commit: 675a4aaf3b226c0089108221b96559e0baae5de9\nPublished-As: https://github.com/gitgitgadget/git/releases/tag/pr-708%2Fvadim-vj%2Fcacheinfo-modern-format-v1\nFetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-708/vadim-vj/cacheinfo-modern-format-v1\nPull-Request: https://github.com/gitgitgadget/git/pull/708\n-- \ngitgitgadget\n"},{"id":"404319","messageId":"f4ea4f6c69edfd5ab67bda9c1024c4aa0df3247e.1598280706.git.gitgitgadget@gmail.com","threadId":"54123","inReplyTo":"pull.708.git.1598280703.gitgitgadget@gmail.com","subject":"[PATCH 2/2] Unify `update-index --cacheinfo` usage (tests)","fromName":"Vadim Sannikov via GitGitGadget","fromEmail":"gitgitgadget@gmail.com","sentAt":"2020-08-24T14:51:43Z","receivedAt":"2020-08-24T14:52:09Z","isPatch":true,"sender":{"key":"name:Vadim Sannikov","avatar":null},"body":"From: Vadim Sannikov <vsj.vadim@gmail.com>\n\nThe old three separate parameters format (`<mode> <object> <path>`)\nis replaced with the modern, single-parameter form\n(`<mode>,<object>,<path>`).\n\nDifferent parts of Git code use different syntax, so the commit unifies\nit. According to `git-update-index` manual page, the new form is\npreferred.\n\nSigned-off-by: Vadim Sannikov <vsj.vadim@gmail.com>\n---\n t/lib-submodule-update.sh         |  2 +-\n t/t0028-working-tree-encoding.sh  |  4 ++--\n t/t1006-cat-file.sh               |  2 +-\n t/t1010-mktree.sh                 |  2 +-\n t/t1050-large.sh                  |  2 +-\n t/t1450-fsck.sh                   |  4 ++--\n t/t3600-rm.sh                     |  4 ++--\n t/t5520-pull.sh                   |  2 +-\n t/t5526-fetch-submodules.sh       | 18 +++++++++---------\n t/t5531-deep-submodule-push.sh    |  2 +-\n t/t6130-pathspec-noglob.sh        |  2 +-\n t/t6430-merge-recursive.sh        |  2 +-\n t/t7003-filter-branch.sh          |  2 +-\n t/t7011-skip-worktree-reading.sh  |  4 ++--\n t/t7012-skip-worktree-writing.sh  |  4 ++--\n t/t7113-post-index-change-hook.sh |  2 +-\n t/t7406-submodule-update.sh       |  4 ++--\n t/t9350-fast-export.sh            |  8 ++++----\n t/test-lib-functions.sh           |  2 +-\n 19 files changed, 36 insertions(+), 36 deletions(-)\n\ndiff --git a/t/lib-submodule-update.sh b/t/lib-submodule-update.sh\nindex 87a759149f..75ce28a9c7 100644\n--- a/t/lib-submodule-update.sh\n+++ b/t/lib-submodule-update.sh\n@@ -139,7 +139,7 @@ create_lib_submodule_repo () {\n \t\tgit revert HEAD &&\n \n \t\tgit checkout -b invalid_sub1 add_sub1 &&\n-\t\tgit update-index --cacheinfo 160000 $(test_oid numeric) sub1 &&\n+\t\tgit update-index --cacheinfo 160000,$(test_oid numeric),sub1 &&\n \t\tgit commit -m \"Invalid sub1 commit\" &&\n \t\tgit checkout -b valid_sub1 &&\n \t\tgit revert HEAD &&\ndiff --git a/t/t0028-working-tree-encoding.sh b/t/t0028-working-tree-encoding.sh\nindex bfc4fb9af5..aa4b719da0 100755\n--- a/t/t0028-working-tree-encoding.sh\n+++ b/t/t0028-working-tree-encoding.sh\n@@ -213,7 +213,7 @@ test_expect_success 'error if encoding round trip is not the same during refresh\n \techo \"*.utf16le text working-tree-encoding=utf-16le\" >.gitattributes &&\n \techo \"hallo\" >nonsense.utf16le &&\n \tTEST_HASH=$(git hash-object --no-filters -w nonsense.utf16le) &&\n-\tgit update-index --add --cacheinfo 100644 $TEST_HASH nonsense.utf16le &&\n+\tgit update-index --add --cacheinfo 100644,$TEST_HASH,nonsense.utf16le &&\n \tCOMMIT=$(git commit-tree -p $(git rev-parse HEAD) -m \"plain commit\" $(git write-tree)) &&\n \tgit update-ref refs/heads/master $COMMIT &&\n \n@@ -229,7 +229,7 @@ test_expect_success 'error if encoding garbage is already in Git' '\n \t# This simulates a Git version that has no checkoutEncoding support\n \tcp nobom.utf16be.raw nonsense.utf16 &&\n \tTEST_HASH=$(git hash-object --no-filters -w nonsense.utf16) &&\n-\tgit update-index --add --cacheinfo 100644 $TEST_HASH nonsense.utf16 &&\n+\tgit update-index --add --cacheinfo 100644,$TEST_HASH,nonsense.utf16 &&\n \tCOMMIT=$(git commit-tree -p $(git rev-parse HEAD) -m \"plain commit\" $(git write-tree)) &&\n \tgit update-ref refs/heads/master $COMMIT &&\n \ndiff --git a/t/t1006-cat-file.sh b/t/t1006-cat-file.sh\nindex 2f501d2dc9..b61b46eab4 100755\n--- a/t/t1006-cat-file.sh\n+++ b/t/t1006-cat-file.sh\n@@ -134,7 +134,7 @@ run_tests 'blob' $hello_sha1 $hello_size \"$hello_content\" \"$hello_content\"\n \n test_expect_success '--batch-check without %(rest) considers whole line' '\n \techo \"$hello_sha1 blob $hello_size\" >expect &&\n-\tgit update-index --add --cacheinfo 100644 $hello_sha1 \"white space\" &&\n+\tgit update-index --add --cacheinfo 100644,$hello_sha1,\"white space\" &&\n \ttest_when_finished \"git update-index --remove \\\"white space\\\"\" &&\n \techo \":white space\" | git cat-file --batch-check >actual &&\n \ttest_cmp expect actual\ndiff --git a/t/t1010-mktree.sh b/t/t1010-mktree.sh\nindex b946f87686..558907af58 100755\n--- a/t/t1010-mktree.sh\n+++ b/t/t1010-mktree.sh\n@@ -23,7 +23,7 @@ test_expect_success setup '\n \ttest_tick &&\n \tgit commit -q -m one &&\n \tH=$(git rev-parse HEAD) &&\n-\tgit update-index --add --cacheinfo 160000 $H sub &&\n+\tgit update-index --add --cacheinfo 160000,$H,sub &&\n \ttest_tick &&\n \tgit commit -q -m two &&\n \tgit rev-parse HEAD^{tree} >tree.withsub &&\ndiff --git a/t/t1050-large.sh b/t/t1050-large.sh\nindex 61e89a8071..05d35d20d9 100755\n--- a/t/t1050-large.sh\n+++ b/t/t1050-large.sh\n@@ -90,7 +90,7 @@ test_expect_success 'add a large file or two' '\n \n test_expect_success 'checkout a large file' '\n \tlarge1=$(git rev-parse :large1) &&\n-\tgit update-index --add --cacheinfo 100644 $large1 another &&\n+\tgit update-index --add --cacheinfo 100644,$large1,another &&\n \tgit checkout another &&\n \ttest_cmp large1 another\n '\ndiff --git a/t/t1450-fsck.sh b/t/t1450-fsck.sh\nindex b17f5c21fb..643af25e3e 100755\n--- a/t/t1450-fsck.sh\n+++ b/t/t1450-fsck.sh\n@@ -59,7 +59,7 @@ test_expect_success 'object with bad sha1' '\n \tsha=\"$(dirname $new)$(basename $new)\" &&\n \tmv .git/objects/$old .git/objects/$new &&\n \ttest_when_finished \"remove_object $sha\" &&\n-\tgit update-index --add --cacheinfo 100644 $sha foo &&\n+\tgit update-index --add --cacheinfo 100644,$sha,foo &&\n \ttest_when_finished \"git read-tree -u --reset HEAD\" &&\n \ttree=$(git write-tree) &&\n \ttest_when_finished \"remove_object $tree\" &&\n@@ -438,7 +438,7 @@ test_expect_success 'rev-list --verify-objects with bad sha1' '\n \tsha=\"$(dirname $new)$(basename $new)\" &&\n \tmv .git/objects/$old .git/objects/$new &&\n \ttest_when_finished \"remove_object $sha\" &&\n-\tgit update-index --add --cacheinfo 100644 $sha foo &&\n+\tgit update-index --add --cacheinfo 100644,$sha,foo &&\n \ttest_when_finished \"git read-tree -u --reset HEAD\" &&\n \ttree=$(git write-tree) &&\n \ttest_when_finished \"remove_object $tree\" &&\ndiff --git a/t/t3600-rm.sh b/t/t3600-rm.sh\nindex efec8d13b6..a78a6b161b 100755\n--- a/t/t3600-rm.sh\n+++ b/t/t3600-rm.sh\n@@ -305,7 +305,7 @@ EOF\n test_expect_success 'rm removes empty submodules from work tree' '\n \tmkdir submod &&\n \thash=$(git rev-parse HEAD) &&\n-\tgit update-index --add --cacheinfo 160000 \"$hash\" submod &&\n+\tgit update-index --add --cacheinfo 160000,\"$hash\",submod &&\n \tgit config -f .gitmodules submodule.sub.url ./. &&\n \tgit config -f .gitmodules submodule.sub.path submod &&\n \tgit submodule init &&\n@@ -632,7 +632,7 @@ test_expect_success 'setup subsubmodule' '\n \t(\n \t\tcd submod &&\n \t\thash=$(git rev-parse HEAD) &&\n-\t\tgit update-index --add --cacheinfo 160000 \"$hash\" subsubmod &&\n+\t\tgit update-index --add --cacheinfo 160000,\"$hash\",subsubmod &&\n \t\tgit config -f .gitmodules submodule.sub.url ../. &&\n \t\tgit config -f .gitmodules submodule.sub.path subsubmod &&\n \t\tgit submodule init &&\ndiff --git a/t/t5520-pull.sh b/t/t5520-pull.sh\nindex 9fae07cdfa..3be5b64030 100755\n--- a/t/t5520-pull.sh\n+++ b/t/t5520-pull.sh\n@@ -350,7 +350,7 @@ test_expect_success 'failed --rebase shows advice' '\n \tgit checkout -b diverging &&\n \ttest_commit attributes .gitattributes \"* text=auto\" attrs &&\n \tsha1=\"$(printf \"1\\\\r\\\\n\" | git hash-object -w --stdin)\" &&\n-\tgit update-index --cacheinfo 0644 $sha1 file &&\n+\tgit update-index --cacheinfo 0644,$sha1,file &&\n \tgit commit -m v1-with-cr &&\n \t# force checkout because `git reset --hard` will not leave clean `file`\n \tgit checkout -f -b fails-to-rebase HEAD^ &&\ndiff --git a/t/t5526-fetch-submodules.sh b/t/t5526-fetch-submodules.sh\nindex 63205dfdf9..470f470b3e 100755\n--- a/t/t5526-fetch-submodules.sh\n+++ b/t/t5526-fetch-submodules.sh\n@@ -614,12 +614,12 @@ test_expect_success \"fetch new submodule commits on-demand outside standard refs\n \n \tC=$(git -C submodule commit-tree -m \"new change outside refs/heads\" HEAD^{tree}) &&\n \tgit -C submodule update-ref refs/changes/1 $C &&\n-\tgit update-index --cacheinfo 160000 $C submodule &&\n+\tgit update-index --cacheinfo 160000,$C,submodule &&\n \ttest_tick &&\n \n \tD=$(git -C sub1 commit-tree -m \"new change outside refs/heads\" HEAD^{tree}) &&\n \tgit -C sub1 update-ref refs/changes/2 $D &&\n-\tgit update-index --cacheinfo 160000 $D sub1 &&\n+\tgit update-index --cacheinfo 160000,$D,sub1 &&\n \n \tgit commit -m \"updated submodules outside of refs/heads\" &&\n \tE=$(git rev-parse HEAD) &&\n@@ -638,12 +638,12 @@ test_expect_success 'fetch new submodule commit on-demand in FETCH_HEAD' '\n \n \tC=$(git -C submodule commit-tree -m \"another change outside refs/heads\" HEAD^{tree}) &&\n \tgit -C submodule update-ref refs/changes/4 $C &&\n-\tgit update-index --cacheinfo 160000 $C submodule &&\n+\tgit update-index --cacheinfo 160000,$C,submodule &&\n \ttest_tick &&\n \n \tD=$(git -C sub1 commit-tree -m \"another change outside refs/heads\" HEAD^{tree}) &&\n \tgit -C sub1 update-ref refs/changes/5 $D &&\n-\tgit update-index --cacheinfo 160000 $D sub1 &&\n+\tgit update-index --cacheinfo 160000,$D,sub1 &&\n \n \tgit commit -m \"updated submodules outside of refs/heads\" &&\n \tE=$(git rev-parse HEAD) &&\n@@ -669,12 +669,12 @@ test_expect_success 'fetch new submodule commits on-demand without .gitmodules e\n \n \tC=$(git -C submodule commit-tree -m \"yet another change outside refs/heads\" HEAD^{tree}) &&\n \tgit -C submodule update-ref refs/changes/7 $C &&\n-\tgit update-index --cacheinfo 160000 $C submodule &&\n+\tgit update-index --cacheinfo 160000,$C,submodule &&\n \ttest_tick &&\n \n \tD=$(git -C sub1 commit-tree -m \"yet another change outside refs/heads\" HEAD^{tree}) &&\n \tgit -C sub1 update-ref refs/changes/8 $D &&\n-\tgit update-index --cacheinfo 160000 $D sub1 &&\n+\tgit update-index --cacheinfo 160000,$D,sub1 &&\n \n \tgit commit -m \"updated submodules outside of refs/heads\" &&\n \tE=$(git rev-parse HEAD) &&\n@@ -696,15 +696,15 @@ test_expect_success 'fetch new submodule commit intermittently referenced by sup\n \tF=$(git -C sub1 commit-tree -m \"change 12 outside refs/heads\" HEAD^{tree}) &&\n \n \tgit -C sub1 update-ref refs/changes/10 $D &&\n-\tgit update-index --cacheinfo 160000 $D sub1 &&\n+\tgit update-index --cacheinfo 160000,$D,sub1 &&\n \tgit commit -m \"updated submodules outside of refs/heads\" &&\n \n \tgit -C sub1 update-ref refs/changes/11 $E &&\n-\tgit update-index --cacheinfo 160000 $E sub1 &&\n+\tgit update-index --cacheinfo 160000,$E,sub1 &&\n \tgit commit -m \"updated submodules outside of refs/heads\" &&\n \n \tgit -C sub1 update-ref refs/changes/12 $F &&\n-\tgit update-index --cacheinfo 160000 $F sub1 &&\n+\tgit update-index --cacheinfo 160000,$F,sub1 &&\n \tgit commit -m \"updated submodules outside of refs/heads\" &&\n \n \tG=$(git rev-parse HEAD) &&\ndiff --git a/t/t5531-deep-submodule-push.sh b/t/t5531-deep-submodule-push.sh\nindex 4ad059e6be..7b5dc2df00 100755\n--- a/t/t5531-deep-submodule-push.sh\n+++ b/t/t5531-deep-submodule-push.sh\n@@ -301,7 +301,7 @@ test_expect_success 'push succeeds if submodule commit disabling recursion from\n test_expect_success 'submodule entry pointing at a tag is error' '\n \tgit -C work/gar/bage tag -a test1 -m \"tag\" &&\n \ttag=$(git -C work/gar/bage rev-parse test1^{tag}) &&\n-\tgit -C work update-index --cacheinfo 160000 \"$tag\" gar/bage &&\n+\tgit -C work update-index --cacheinfo 160000,\"$tag\",gar/bage &&\n \tgit -C work commit -m \"bad commit\" &&\n \ttest_when_finished \"git -C work reset --hard HEAD^\" &&\n \ttest_must_fail git -C work push --recurse-submodules=on-demand ../pub.git master 2>err &&\ndiff --git a/t/t6130-pathspec-noglob.sh b/t/t6130-pathspec-noglob.sh\nindex ba7902c9cd..bd9cb80feb 100755\n--- a/t/t6130-pathspec-noglob.sh\n+++ b/t/t6130-pathspec-noglob.sh\n@@ -11,7 +11,7 @@ test_expect_success 'create commits with glob characters' '\n \t# on Windows (the tests below do not depend on the presence\n \t# of the file in the worktree)\n \tgit config core.protectNTFS false &&\n-\tgit update-index --add --cacheinfo 100644 \"$(git rev-parse HEAD:foo)\" \"f*\" &&\n+\tgit update-index --add --cacheinfo 100644,\"$(git rev-parse HEAD:foo)\",\"f*\" &&\n \ttest_tick &&\n \tgit commit -m star &&\n \ttest_commit bracket \"f[o][o]\"\ndiff --git a/t/t6430-merge-recursive.sh b/t/t6430-merge-recursive.sh\nindex d48d211a95..c7766deb3a 100755\n--- a/t/t6430-merge-recursive.sh\n+++ b/t/t6430-merge-recursive.sh\n@@ -246,7 +246,7 @@ test_expect_success 'setup 7' '\n \tgit rm d/e &&\n \ttest_tick &&\n \tgit commit -m \"remove d/e\" &&\n-\tgit update-index --add --cacheinfo 160000 $c1 d &&\n+\tgit update-index --add --cacheinfo 160000,$c1,d &&\n \ttest_tick &&\n \tgit commit -m \"make d/ a submodule\"\n '\ndiff --git a/t/t7003-filter-branch.sh b/t/t7003-filter-branch.sh\nindex 36477cb1f4..49c7fff29e 100755\n--- a/t/t7003-filter-branch.sh\n+++ b/t/t7003-filter-branch.sh\n@@ -467,7 +467,7 @@ test_expect_success 'replace submodule revision' '\n \tgit reset --hard original &&\n \tgit filter-branch -f --tree-filter \\\n \t    \"if git ls-files --error-unmatch -- submod > /dev/null 2>&1\n-\t     then git update-index --cacheinfo 160000 $invalid submod\n+\t     then git update-index --cacheinfo 160000,$invalid,submod\n \t     fi\" HEAD &&\n \ttest $orig_head != $(git show-ref --hash --head HEAD)\n '\ndiff --git a/t/t7011-skip-worktree-reading.sh b/t/t7011-skip-worktree-reading.sh\nindex 37525cae3a..97f4cbedf5 100755\n--- a/t/t7011-skip-worktree-reading.sh\n+++ b/t/t7011-skip-worktree-reading.sh\n@@ -26,7 +26,7 @@ EOF\n setup_absent() {\n \ttest -f 1 && rm 1\n \tgit update-index --remove 1 &&\n-\tgit update-index --add --cacheinfo 100644 $EMPTY_BLOB 1 &&\n+\tgit update-index --add --cacheinfo 100644,$EMPTY_BLOB,1 &&\n \tgit update-index --skip-worktree 1\n }\n \n@@ -40,7 +40,7 @@ test_absent() {\n setup_dirty() {\n \tgit update-index --force-remove 1 &&\n \techo dirty > 1 &&\n-\tgit update-index --add --cacheinfo 100644 $EMPTY_BLOB 1 &&\n+\tgit update-index --add --cacheinfo 100644,$EMPTY_BLOB,1 &&\n \tgit update-index --skip-worktree 1\n }\n \ndiff --git a/t/t7012-skip-worktree-writing.sh b/t/t7012-skip-worktree-writing.sh\nindex 7476781979..1ad17d3606 100755\n--- a/t/t7012-skip-worktree-writing.sh\n+++ b/t/t7012-skip-worktree-writing.sh\n@@ -56,7 +56,7 @@ test_expect_success 'read-tree removes worktree, dirty case' '\n setup_absent() {\n \ttest -f 1 && rm 1\n \tgit update-index --remove 1 &&\n-\tgit update-index --add --cacheinfo 100644 $EMPTY_BLOB 1 &&\n+\tgit update-index --add --cacheinfo 100644,$EMPTY_BLOB,1 &&\n \tgit update-index --skip-worktree 1\n }\n \n@@ -70,7 +70,7 @@ test_absent() {\n setup_dirty() {\n \tgit update-index --force-remove 1 &&\n \techo dirty > 1 &&\n-\tgit update-index --add --cacheinfo 100644 $EMPTY_BLOB 1 &&\n+\tgit update-index --add --cacheinfo 100644,$EMPTY_BLOB,1 &&\n \tgit update-index --skip-worktree 1\n }\n \ndiff --git a/t/t7113-post-index-change-hook.sh b/t/t7113-post-index-change-hook.sh\nindex f011ad7eec..4272f542ca 100755\n--- a/t/t7113-post-index-change-hook.sh\n+++ b/t/t7113-post-index-change-hook.sh\n@@ -132,7 +132,7 @@ test_expect_success 'test reset --mixed and update-index triggers the hook' '\n \ttest_path_is_file testsuccess && rm -f testsuccess &&\n \ttest_path_is_missing testfailure &&\n \tgit hash-object -w --stdin <dir1/file2.txt >expect &&\n-\tgit update-index --cacheinfo 100644 \"$(cat expect)\" dir1/file1.txt &&\n+\tgit update-index --cacheinfo 100644,\"$(cat expect)\",dir1/file1.txt &&\n \ttest_path_is_file testsuccess && rm -f testsuccess &&\n \ttest_path_is_missing testfailure &&\n \tgit update-index --skip-worktree dir1/file2.txt &&\ndiff --git a/t/t7406-submodule-update.sh b/t/t7406-submodule-update.sh\nindex aa19ff3a2e..404353d411 100755\n--- a/t/t7406-submodule-update.sh\n+++ b/t/t7406-submodule-update.sh\n@@ -517,7 +517,7 @@ test_expect_success 'submodule init does not copy command into .git/config' '\n \t git ls-files -s submodule >out &&\n \t H=$(cut -d\" \" -f2 out) &&\n \t mkdir submodule1 &&\n-\t git update-index --add --cacheinfo 160000 $H submodule1 &&\n+\t git update-index --add --cacheinfo 160000,$H,submodule1 &&\n \t git config -f .gitmodules submodule.submodule1.path submodule1 &&\n \t git config -f .gitmodules submodule.submodule1.url ../submodule &&\n \t git config -f .gitmodules submodule.submodule1.update !false &&\n@@ -928,7 +928,7 @@ test_expect_success 'submodule update properly revives a moved submodule' '\n \t git rm --cached submodule2 &&\n \t rm -rf submodule2 &&\n \t mkdir -p \"moved/sub module\" &&\n-\t git update-index --add --cacheinfo 160000 $H \"moved/sub module\" &&\n+\t git update-index --add --cacheinfo 160000,$H,\"moved/sub module\" &&\n \t git config -f .gitmodules submodule.submodule2.path \"moved/sub module\" &&\n \t git commit -am \"post move\" &&\n \t git submodule update &&\ndiff --git a/t/t9350-fast-export.sh b/t/t9350-fast-export.sh\nindex 1372842559..9135b75e2e 100755\n--- a/t/t9350-fast-export.sh\n+++ b/t/t9350-fast-export.sh\n@@ -604,10 +604,10 @@ test_expect_success 'fast-export quotes pathnames' '\n \t(cd crazy-paths &&\n \t blob=$(echo foo | git hash-object -w --stdin) &&\n \t git -c core.protectNTFS=false update-index --add \\\n-\t\t--cacheinfo 100644 $blob \"$(printf \"path with\\\\nnewline\")\" \\\n-\t\t--cacheinfo 100644 $blob \"path with \\\"quote\\\"\" \\\n-\t\t--cacheinfo 100644 $blob \"path with \\\\backslash\" \\\n-\t\t--cacheinfo 100644 $blob \"path with space\" &&\n+\t\t--cacheinfo 100644,$blob,\"$(printf \"path with\\\\nnewline\")\" \\\n+\t\t--cacheinfo 100644,$blob,\"path with \\\"quote\\\"\" \\\n+\t\t--cacheinfo 100644,$blob,\"path with \\\\backslash\" \\\n+\t\t--cacheinfo 100644,$blob,\"path with space\" &&\n \t git commit -m addition &&\n \t git ls-files -z -s | perl -0pe \"s{\\\\t}{$&subdir/}\" >index &&\n \t git read-tree --empty &&\ndiff --git a/t/test-lib-functions.sh b/t/test-lib-functions.sh\nindex 6a8e194a99..dc5e9af6c6 100644\n--- a/t/test-lib-functions.sh\n+++ b/t/test-lib-functions.sh\n@@ -1230,7 +1230,7 @@ test_ln_s_add () {\n \telse\n \t\tprintf '%s' \"$1\" >\"$2\" &&\n \t\tln_s_obj=$(git hash-object -w \"$2\") &&\n-\t\tgit update-index --add --cacheinfo 120000 $ln_s_obj \"$2\" &&\n+\t\tgit update-index --add --cacheinfo 120000,$ln_s_obj,\"$2\" &&\n \t\t# pick up stat info from the file\n \t\tgit update-index \"$2\"\n \tfi\n-- \ngitgitgadget\n"},{"id":"404351","messageId":"xmqqv9h7513d.fsf@gitster.c.googlers.com","threadId":"54123","inReplyTo":"fc2138e1db2de46793100b87c00dbde270f6b350.1598280704.git.gitgitgadget@gmail.com","subject":"Re: [PATCH 1/2] Unify `update-index --cacheinfo` usage","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2020-08-24T18:51:34Z","receivedAt":"2020-08-24T18:51:47Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"\"Vadim Sannikov via GitGitGadget\" <gitgitgadget@gmail.com> writes:\n\n> Subject: Re: [PATCH 1/2] Unify `update-index --cacheinfo` usage\n\nPerhaps\n\n\tupdate-index: use single-argument form of --cacheinfo\n\nsee Documentation/SubmittingPatches[[summary-section]]\n\n> Different parts of Git code use different syntax, so the commit unifies\n> it. According to `git-update-index` manual page, the new form is\n> preferred.\n\nIt is _encouraged_ to new users, but it is not like the old form is\ngetting removed.  IOW, there is no strong \"preference\".\n\n\tThe \"--cacheinfo\" option of \"update-index\" can take two\n\tforms, but we encourage new users to use the form where the\n\tmode, object, and path are concatenated with a comma, into a\n\tsingle parameter.  Update the in-tree users of the command\n\tto also use the form to help new users who may want to copy\n\tand paste from our code.\n\nor something?\n\nThis step is good, but it is not welcome to change the tests in such\na way that the three-separate-parameter form is not tested at all.\nAs long as we have tests to ensure the single-parameter form works\nOK, no change is needed.\n\nThanks.\n\n> Signed-off-by: Vadim Sannikov <vsj.vadim@gmail.com>\n> ---\n>  git-merge-one-file.sh | 6 +++---\n>  git-mergetool.sh      | 2 +-\n>  merge-recursive.c     | 2 +-\n>  po/bg.po              | 4 ++--\n>  po/ca.po              | 4 ++--\n>  po/de.po              | 4 ++--\n>  po/el.po              | 2 +-\n>  po/es.po              | 4 ++--\n>  po/fr.po              | 4 ++--\n>  po/git.pot            | 2 +-\n>  po/it.po              | 4 ++--\n>  po/ko.po              | 4 ++--\n>  po/ru.po              | 8 ++++++--\n>  po/sv.po              | 4 ++--\n>  po/tr.po              | 4 ++--\n>  po/vi.po              | 4 ++--\n>  po/zh_CN.po           | 4 ++--\n>  po/zh_TW.po           | 4 ++--\n>  18 files changed, 37 insertions(+), 33 deletions(-)\n>\n> diff --git a/git-merge-one-file.sh b/git-merge-one-file.sh\n> index f6d9852d2f..5691c4e7ff 100755\n> --- a/git-merge-one-file.sh\n> +++ b/git-merge-one-file.sh\n> @@ -71,7 +71,7 @@ case \"${1:-.}${2:-.}${3:-.}\" in\n>  \".$2.\")\n>  \t# the other side did not add and we added so there is nothing\n>  \t# to be done, except making the path merged.\n> -\texec git update-index --add --cacheinfo \"$6\" \"$2\" \"$4\"\n> +\texec git update-index --add --cacheinfo \"$6\",\"$2\",\"$4\"\n>  \t;;\n>  \"..$3\")\n>  \techo \"Adding $4\"\n> @@ -80,7 +80,7 @@ case \"${1:-.}${2:-.}${3:-.}\" in\n>  \t\techo \"ERROR: untracked $4 is overwritten by the merge.\" >&2\n>  \t\texit 1\n>  \tfi\n> -\tgit update-index --add --cacheinfo \"$7\" \"$3\" \"$4\" &&\n> +\tgit update-index --add --cacheinfo \"$7\",\"$3\",\"$4\" &&\n>  \t\texec git checkout-index -u -f -- \"$4\"\n>  \t;;\n>  \n> @@ -95,7 +95,7 @@ case \"${1:-.}${2:-.}${3:-.}\" in\n>  \t\texit 1\n>  \tfi\n>  \techo \"Adding $4\"\n> -\tgit update-index --add --cacheinfo \"$6\" \"$2\" \"$4\" &&\n> +\tgit update-index --add --cacheinfo \"$6\",\"$2\",\"$4\" &&\n>  \t\texec git checkout-index -u -f -- \"$4\"\n>  \t;;\n>  \n> diff --git a/git-mergetool.sh b/git-mergetool.sh\n> index e3f6d543fb..ad37b15f4b 100755\n> --- a/git-mergetool.sh\n> +++ b/git-mergetool.sh\n> @@ -224,7 +224,7 @@ stage_submodule () {\n>  \t)\n>  \ttest -n \"$work_rel_path\" ||\n>  \tdie \"fatal: unable to get path of module $path relative to work tree\"\n> -\tgit update-index --add --replace --cacheinfo 160000 \"$submodule_sha1\" \"${work_rel_path%/}\" || die\n> +\tgit update-index --add --replace --cacheinfo 160000,\"$submodule_sha1\",\"${work_rel_path%/}\" || die\n>  }\n>  \n>  checkout_staged_file () {\n> diff --git a/merge-recursive.c b/merge-recursive.c\n> index d0214335a7..dfe6f67ec8 100644\n> --- a/merge-recursive.c\n> +++ b/merge-recursive.c\n> @@ -1259,7 +1259,7 @@ static int merge_submodule(struct merge_options *opt,\n>  \t\t       \"If this is correct simply add it to the index \"\n>  \t\t       \"for example\\n\"\n>  \t\t       \"by using:\\n\\n\"\n> -\t\t       \"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\\n\"\n> +\t\t       \"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\\n\"\n>  \t\t       \"which will accept this suggestion.\\n\"),\n>  \t\t       oid_to_hex(&merges.objects[0].item->oid), path);\n>  \t\tbreak;\n> diff --git a/po/bg.po b/po/bg.po\n> index a189b16dc4..517c0e6b49 100644\n> --- a/po/bg.po\n> +++ b/po/bg.po\n> @@ -4737,13 +4737,13 @@ msgid \"\"\n>  \"If this is correct simply add it to the index for example\\n\"\n>  \"by using:\\n\"\n>  \"\\n\"\n> -\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"which will accept this suggestion.\\n\"\n>  msgstr \"\"\n>  \"Ако това е така, добавете го към индекса с команда като следната:\\n\"\n>  \"\\n\"\n> -\"    git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"Това приема предложеното.\\n\"\n>  \n> diff --git a/po/ca.po b/po/ca.po\n> index c43c21bc22..61c3a7f9b0 100644\n> --- a/po/ca.po\n> +++ b/po/ca.po\n> @@ -4592,12 +4592,12 @@ msgid \"\"\n>  \"If this is correct simply add it to the index for example\\n\"\n>  \"by using:\\n\"\n>  \"\\n\"\n> -\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"which will accept this suggestion.\\n\"\n>  msgstr \"\"\n>  \"Si això és correcte simplement afegiu-ho a l'índex per exemple utilitzant \"\n> -\"git update-index --cacheinfo 160000 per cents \\\"%s\\\" que acceptaran aquest \"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\" que acceptaran aquest \"\n>  \"suggeriment.\\n\"\n>  \n>  #: merge-recursive.c:1268\n> diff --git a/po/de.po b/po/de.po\n> index 656de24218..ec0106f2b8 100644\n> --- a/po/de.po\n> +++ b/po/de.po\n> @@ -4641,14 +4641,14 @@ msgid \"\"\n>  \"If this is correct simply add it to the index for example\\n\"\n>  \"by using:\\n\"\n>  \"\\n\"\n> -\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"which will accept this suggestion.\\n\"\n>  msgstr \"\"\n>  \"Falls das korrekt ist, fügen Sie es einfach der Staging-Area, zum Beispiel \"\n>  \"mit:\\n\"\n>  \"\\n\"\n> -\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"hinzu, um diesen Vorschlag zu akzeptieren.\\n\"\n>  \n> diff --git a/po/el.po b/po/el.po\n> index 703f46d0c7..e775885187 100644\n> --- a/po/el.po\n> +++ b/po/el.po\n> @@ -3075,7 +3075,7 @@ msgid \"\"\n>  \"If this is correct simply add it to the index for example\\n\"\n>  \"by using:\\n\"\n>  \"\\n\"\n> -\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"which will accept this suggestion.\\n\"\n>  msgstr \"\"\n> diff --git a/po/es.po b/po/es.po\n> index 41a72ca6fb..1c1aeebe47 100644\n> --- a/po/es.po\n> +++ b/po/es.po\n> @@ -4572,14 +4572,14 @@ msgid \"\"\n>  \"If this is correct simply add it to the index for example\\n\"\n>  \"by using:\\n\"\n>  \"\\n\"\n> -\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"which will accept this suggestion.\\n\"\n>  msgstr \"\"\n>  \"Si esto es correcto simplemente agrégalo al índice por ejemplo\\n\"\n>  \"usando:\\n\"\n>  \"\\n\"\n> -\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"el cual aceptará esta sugerencia.\\n\"\n>  \n> diff --git a/po/fr.po b/po/fr.po\n> index d20fc440ab..157c41ff4c 100644\n> --- a/po/fr.po\n> +++ b/po/fr.po\n> @@ -4714,14 +4714,14 @@ msgid \"\"\n>  \"If this is correct simply add it to the index for example\\n\"\n>  \"by using:\\n\"\n>  \"\\n\"\n> -\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"which will accept this suggestion.\\n\"\n>  msgstr \"\"\n>  \"Si c'est correct, ajoutez le simplement à l'index\\n\"\n>  \"en utilisant par exemple :\\n\"\n>  \"\\n\"\n> -\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"qui acceptera cette suggestion.\\n\"\n>  \n> diff --git a/po/git.pot b/po/git.pot\n> index 198b6e0a4a..2d50bebf5a 100644\n> --- a/po/git.pot\n> +++ b/po/git.pot\n> @@ -4256,7 +4256,7 @@ msgid \"\"\n>  \"If this is correct simply add it to the index for example\\n\"\n>  \"by using:\\n\"\n>  \"\\n\"\n> -\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"which will accept this suggestion.\\n\"\n>  msgstr \"\"\n> diff --git a/po/it.po b/po/it.po\n> index 53523e76df..c8264dd7bc 100644\n> --- a/po/it.po\n> +++ b/po/it.po\n> @@ -4649,14 +4649,14 @@ msgid \"\"\n>  \"If this is correct simply add it to the index for example\\n\"\n>  \"by using:\\n\"\n>  \"\\n\"\n> -\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"which will accept this suggestion.\\n\"\n>  msgstr \"\"\n>  \"Se è corretta aggiungila semplicemente all'indice, ad esempio\\n\"\n>  \"usando:\\n\"\n>  \"\\n\"\n> -\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"per accettare questo suggerimento.\\n\"\n>  \n> diff --git a/po/ko.po b/po/ko.po\n> index dcfe21c223..47b611edee 100644\n> --- a/po/ko.po\n> +++ b/po/ko.po\n> @@ -2361,14 +2361,14 @@ msgid \"\"\n>  \"If this is correct simply add it to the index for example\\n\"\n>  \"by using:\\n\"\n>  \"\\n\"\n> -\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"which will accept this suggestion.\\n\"\n>  msgstr \"\"\n>  \"이 제안이 맞으면 인덱스에 추가하면 됩니다. 예를 들어\\n\"\n>  \"다음 명령을 사용하면:\\n\"\n>  \"\\n\"\n> -\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"제안을 받아들이게 됩니다.\\n\"\n>  \n> diff --git a/po/ru.po b/po/ru.po\n> index a77b462e62..a928cd879e 100644\n> --- a/po/ru.po\n> +++ b/po/ru.po\n> @@ -3523,10 +3523,14 @@ msgid \"\"\n>  \"If this is correct simply add it to the index for example\\n\"\n>  \"by using:\\n\"\n>  \"\\n\"\n> -\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"which will accept this suggestion.\\n\"\n> -msgstr \"Если оно верное, то просто добавьте его в индекс, например так:\\n\\n  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\\nтем самым принимая это предположение.\\n\"\n> +msgstr \"Если оно верное, то просто добавьте его в индекс, например так:\\n\"\n> +\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n> +\"\\n\"\n> +\"тем самым принимая это предположение.\\n\"\n>  \n>  #: merge-recursive.c:1252\n>  #, c-format\n> diff --git a/po/sv.po b/po/sv.po\n> index 93f3c6f3f7..f5a850f0b7 100644\n> --- a/po/sv.po\n> +++ b/po/sv.po\n> @@ -4551,14 +4551,14 @@ msgid \"\"\n>  \"If this is correct simply add it to the index for example\\n\"\n>  \"by using:\\n\"\n>  \"\\n\"\n> -\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"which will accept this suggestion.\\n\"\n>  msgstr \"\"\n>  \"Om detta är riktigt lägger du bara till det i indexet, till\\n\"\n>  \"exempel så här:\\n\"\n>  \"\\n\"\n> -\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"vilket godtar lösningen.\\n\"\n>  \n> diff --git a/po/tr.po b/po/tr.po\n> index 9a17c19b25..af5f9ba7f8 100644\n> --- a/po/tr.po\n> +++ b/po/tr.po\n> @@ -4619,13 +4619,13 @@ msgid \"\"\n>  \"If this is correct simply add it to the index for example\\n\"\n>  \"by using:\\n\"\n>  \"\\n\"\n> -\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"which will accept this suggestion.\\n\"\n>  msgstr \"\"\n>  \"Eğer bu doğruysa yalnızca indekse ekleyin, örneğinbu öneriyi kabul edecek:\\n\"\n>  \"\\n\"\n> -\"\\tgit update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"komutunu kullanmanız yeterlidir.\\n\"\n>  \n> diff --git a/po/vi.po b/po/vi.po\n> index d730cf1141..beec050125 100644\n> --- a/po/vi.po\n> +++ b/po/vi.po\n> @@ -4548,14 +4548,14 @@ msgid \"\"\n>  \"If this is correct simply add it to the index for example\\n\"\n>  \"by using:\\n\"\n>  \"\\n\"\n> -\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"which will accept this suggestion.\\n\"\n>  msgstr \"\"\n>  \"Nếu đây là đúng đơn giản thêm nó vào mục lục ví dụ\\n\"\n>  \"bằng cách dùng:\\n\"\n>  \"\\n\"\n> -\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"cái mà sẽ chấp nhận gợi ý này.\\n\"\n>  \n> diff --git a/po/zh_CN.po b/po/zh_CN.po\n> index a531819623..69dd29140b 100644\n> --- a/po/zh_CN.po\n> +++ b/po/zh_CN.po\n> @@ -4567,13 +4567,13 @@ msgid \"\"\n>  \"If this is correct simply add it to the index for example\\n\"\n>  \"by using:\\n\"\n>  \"\\n\"\n> -\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"which will accept this suggestion.\\n\"\n>  msgstr \"\"\n>  \"如果这个正确，将其添加到索引，例如使用命令：\\n\"\n>  \"\\n\"\n> -\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"以接受此建议。\\n\"\n>  \n> diff --git a/po/zh_TW.po b/po/zh_TW.po\n> index 9334b46faa..18e6b8985a 100644\n> --- a/po/zh_TW.po\n> +++ b/po/zh_TW.po\n> @@ -4692,13 +4692,13 @@ msgid \"\"\n>  \"If this is correct simply add it to the index for example\\n\"\n>  \"by using:\\n\"\n>  \"\\n\"\n> -\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"which will accept this suggestion.\\n\"\n>  msgstr \"\"\n>  \"如果這個正確，將其新增到索引，例如使用指令：\\n\"\n>  \"\\n\"\n> -\"  git update-index --cacheinfo 160000 %s \\\"%s\\\"\\n\"\n> +\"  git update-index --cacheinfo 160000,%s,\\\"%s\\\"\\n\"\n>  \"\\n\"\n>  \"以接受此建議。\\n\"\n"}]}