[PATCH v2 0/1] submodule foreach: fix recursion of options
- From
Morian Sonnet via GitGitGadget <gitgitgadget@gmail.com>
- Date
- Jun 12, 2019, 20:28 UTC
- Message-ID
- <pull.263.v2.git.gitgitgadget@gmail.com>
- In-Reply-To
- <pull.263.git.gitgitgadget@gmail.com>
During the usage of git in Buildkite we noted that git fails upon calling git submodule foreach --recursive git reset --hardafter updating git version to 2.22.0.
This is due to a problem with the recursive calling of git submodule--helper itself, which is fixed in the patch below.
Morian Sonnet (1): submodule foreach: fix recursion of options
builtin/submodule--helper.c | 1 + t/t7407-submodule-foreach.sh | 7 +++++++ 2 files changed, 8 insertions(+)
base-commit: b697d92f56511e804b8ba20ccbe7bdc85dc66810 Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-263%2Fmomoson%2Fmaster-v2 Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-263/momoson/master-v2 Pull-Request: https://github.com/gitgitgadget/git/pull/263
Range-diff vs v1:
1: e766e51777 ! 1: c46e5bd140 submodule foreach: fix recursion of options
@@ -65,8 +65,10 @@
'
+test_expect_success 'option-like arguments passed to foreach recurse correctly' '
-+ cd super &&
-+ git submodule foreach --recursive git reset --hard
++ (
++ cd super &&
++ git submodule foreach --recursive git reset --hard
++ )
+'
+
test_done-- gitgitgadget