Re: [PATCHv2 2/7] revision.h: introduce blob/tree walking in order of the commits

2017-11-01 Thread Junio C Hamano
Johannes Schindelin writes: >> > Given that the test_expect_* functions evaluate the code, it makes me >> > wonder whether those `return` statements really return appropriately, or >> > one call level too low. >> >> The test_expect functions eval the actual snippets

Re: [PATCHv2 2/7] revision.h: introduce blob/tree walking in order of the commits

2017-11-01 Thread Stefan Beller
On Wed, Nov 1, 2017 at 3:39 PM, Johannes Schindelin wrote: >> not ok 1 - witty title >> >> That is all we want to care about here? > > We care about the loop body being executed successfully *each time*. A > better counter example: Good point. I'll use return in that

Re: [PATCHv2 2/7] revision.h: introduce blob/tree walking in order of the commits

2017-11-01 Thread Johannes Schindelin
Hi Stefan, On Wed, 1 Nov 2017, Stefan Beller wrote: > 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

Re: [PATCHv2 2/7] revision.h: introduce blob/tree walking in order of the commits

2017-11-01 Thread Johannes Schindelin
Hi, On Wed, 1 Nov 2017, Jeff King wrote: > On Wed, Nov 01, 2017 at 10:36:02PM +0100, Johannes Schindelin wrote: > > > On Wed, 1 Nov 2017, Junio C Hamano wrote: > > > > > On Wed, Nov 1, 2017 at 9:26 PM, Johannes Schindelin > > > wrote: > > > > > > > > ... >

Re: [PATCHv2 2/7] revision.h: introduce blob/tree walking in order of the commits

2017-11-01 Thread Stefan Beller
>> 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

Re: [PATCHv2 2/7] revision.h: introduce blob/tree walking in order of the commits

2017-11-01 Thread Johannes Schindelin
Hi Stefan, On Wed, 1 Nov 2017, Stefan Beller wrote: > On Wed, Nov 1, 2017 at 5:37 AM, Junio C Hamano wrote: > > On Wed, Nov 1, 2017 at 9:26 PM, Johannes Schindelin > > wrote: > >> > >> ... > >> ( > >> for x in four

Re: [PATCHv2 2/7] revision.h: introduce blob/tree walking in order of the commits

2017-11-01 Thread Jeff King
On Wed, Nov 01, 2017 at 10:36:02PM +0100, Johannes Schindelin wrote: > Hi Junio, > > On Wed, 1 Nov 2017, Junio C Hamano wrote: > > > On Wed, Nov 1, 2017 at 9:26 PM, Johannes Schindelin > > wrote: > > > > > > ... > > > ( > > > for x in

Re: [PATCHv2 2/7] revision.h: introduce blob/tree walking in order of the commits

2017-11-01 Thread Johannes Schindelin
Hi Junio, On Wed, 1 Nov 2017, Junio C Hamano wrote: > On Wed, Nov 1, 2017 at 9:26 PM, Johannes Schindelin > wrote: > > > > ... > > ( > > for x in four three > > do > > git rm $x && > >

Re: [PATCHv2 2/7] revision.h: introduce blob/tree walking in order of the commits

2017-11-01 Thread Stefan Beller
On Wed, Nov 1, 2017 at 5:37 AM, Junio C Hamano wrote: > On Wed, Nov 1, 2017 at 9:26 PM, Johannes Schindelin > wrote: >> >> ... >> ( >> for x in four three >> do >> git rm $x &&

Re: [PATCHv2 2/7] revision.h: introduce blob/tree walking in order of the commits

2017-11-01 Thread Junio C Hamano
On Wed, Nov 1, 2017 at 9:26 PM, Johannes Schindelin wrote: > > ... > ( > for x in four three > do > git rm $x && > git commit -m "remote $x" || >

Re: [PATCHv2 2/7] revision.h: introduce blob/tree walking in order of the commits

2017-11-01 Thread Johannes Schindelin
Hi, On Wed, 1 Nov 2017, Junio C Hamano wrote: > Stefan Beller writes: > > > diff --git a/t/t6100-rev-list-in-order.sh b/t/t6100-rev-list-in-order.sh > > new file mode 100755 > > index 00..651666979b > > --- /dev/null > > +++ b/t/t6100-rev-list-in-order.sh > > @@

Re: [PATCHv2 2/7] revision.h: introduce blob/tree walking in order of the commits

2017-10-31 Thread Junio C Hamano
Stefan Beller writes: > diff --git a/t/t6100-rev-list-in-order.sh b/t/t6100-rev-list-in-order.sh > new file mode 100755 > index 00..651666979b > --- /dev/null > +++ b/t/t6100-rev-list-in-order.sh > @@ -0,0 +1,46 @@ > +#!/bin/sh > + > +test_description='miscellaneous