Subject: Re: [PATCH v2 7/7] bisect: allows any terms set by user

From: Matthieu Moy <[email-masked]>
Date: Mon, 15 Jun 2015 10:37:23 +0200

Antoine Delaite <[email-masked]> writes:

> Louis Stuber <[email-masked]> writes: 
>
>>Matthieu Moy <[email-masked]> writes: 
>> 
>>> Modifying in PATCH 7 some code that you introduced in PATCH 3 is 
>>> suspicious. Is there any reason you did not name the variable 
>>> "terms_defined" in the first place? (i.e. squash this hunk and the other 
>>> instance of start_bad_good into PATCH 3) 
>>> 
>>> (Whether this is a rethorical question is up to you ;-) ) 
>> 
>>In the previouses versions where we only want to introduce old/new, 
>>the terms can only be defined in bisect_start if the user typed 
>>start <bad> <good>. The name "start_bad_good" is not very explicit 
>>indeed, but isn't it more appropriate in this case than terms_defined ? 
>
> I agree with Louis, but maybe a consistant commit history is more 
> important. But if only the first patches (which implement old/new ) 
> would come to be accepted the name of the variable would sounds strange. 

I would say terms_defined is OK even if only the first patches get
merged. The reason why you need this variable is because you need to
know whether the terms have been defined or not, and to me that's the
most important.

I'd suggest something like this:

# terms_defined is 0 when the user did not define the terms explicitely
# yet. This is the case when running 'git bisect start bad_rev good_rev'
# before we see an explicit reference to a term.
terms_defined=0

Then PATCH 7/7 can add a mention of 'git bisect terms' just in the
comment.

-- 
Matthieu Moy
http://www-verimag.imag.fr/~moy/