Re: [PATCH RFC v2 08/19] rebase -i: Root commits are replayed with an unnecessary option

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Junio,

Junio C Hamano writes:
> Fabian Ruch <bafain@xxxxxxxxx> writes:
>> It makes the next patch easier to understand because the finalising
>> command line "git commit --allow-empty --amend --no-post-rewrite -n
>> --no-edit" seems to be simply moved to the end of do_pick. Substituting
>> --no-edit for -C there would make that log message overly long ...
> 
> And the reason why the same "-C $1" is not used and "--no-edit" is used
> in the final version that is moved to the end of do_pick is...?

The finalising command line is executed by do_pick to rewrite $1 when it
is being replayed.

For instance, one purpose of rewriting is amending the current head with
the changes introduced by $1. In this case, we don't want the log
message of $1 to be the final log message. Another purpose of rewriting
is using a text file or a string as log message, which would be defeated
by "-C $1" as well.

It's true that, by the time the next patch is introduced, do_pick
doesn't yet implement either rewriting mechanism (they are both used to
thread "squash" through do_pick later on) but these considerations
suggest that "-C $1" might not be what we want to use to disable the log
message editor.

   Fabian
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]