Re: [PATCHv2 2/7] revision.h: introduce blob/tree walking in order of the commits
- From
Stefan Beller <sbeller@google.com>
- Date
- Nov 1, 2017, 22:19 UTC
- Message-ID
- <CAGZ79kbYshVjUh2XhbLHtYmnRuFaCmuWZJZd7HifKAqJbNBPfw@mail.gmail.com>
- In-Reply-To
- <alpine.DEB.2.21.1.1711012307060.6482@virtualbox>
Show 10 quoted lines
>> I think I'll go without the extra subshell and with s/return 1/false/ as >> the exact value doesn't matter. > > You mean > > for ... > do > xyz || > false > done
Yes, I do.
> ? That does not work. Try this: > > for a in 1 2 3; do echo $a && false; done && echo done
... && echo $?
1> While it does not print `done`, it will print all of 1, 2 and 3.
We do not care about the internal state, aborting early, we rather care only if the whole loop body was executed. Running the test
test_expect_success 'witty title' '
for a in 1 2 3; do echo $a && false; done && echo done
'not ok 1 - witty title
That is all we want to care about here? Otherwise I may still have a misunderstanding.
Thanks, Stefan