Re: [PATCH v2 6/6] merge: do not exit restore_state() prematurely
- From
Eric Sunshine <sunshine@sunshineco.com>
- Date
- Jul 20, 2022, 00:09 UTC
- Message-ID
- <CAPig+cTqN6nVRGhm-bG6F2RGACAKi7RYa4yp_qqsp7F5pWVaBA@mail.gmail.com>
- In-Reply-To
- <xmqqzgh466ia.fsf@gitster.g>
[replying to Junio's email since I don't have the original available...]
On Tue, Jul 19, 2022 at 7:22 PM Junio C Hamano <gitster@pobox.com> wrote:
Show 6 quoted lines
> "Elijah Newren via GitGitGadget" <gitgitgadget@gmail.com> writes: > > + for b in branch1 branch2 branch3 > > + do > > + git checkout -b $b main && > > + test_commit --no-tag "Change on $b" base $b > > + done &&
Let's break out of the loop with `|| return 1` if something in the loop body fails.
for b in branch1 branch2 branch3
do
git checkout -b $b main &&
test_commit --no-tag "Change on $b" base $b || return 1
done &&