Re: [PATCH] sequencer: beautify subject of reverts of reverts

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

 



Oswald Buddenhagen <oswald.buddenhagen@xxxxxx> writes:

>>That looks good. And the transformations are just:
>>
>>    Revert " → Reapply "
>>    Reapply " → Revert^3 "
>>    Revert^<n> " → Revert^<n+1> "
>>
> i thought about that already, and concluded that it's getting a bit
> "too nerdy" and over-engineered.

I agree that Revert^<n> looks too nerdy, and suspect that it was
also one of the reasons why the old discussion thread died out, even
though nobody in the thread explicitly mentioned it as the reason
to reject it.

> ...
> but i don't mind, as long as `Revert "Revert "Revert "foo"""` cannot
> be argued to be canon any more.

At least, that form can be mechanically understood what it means
with a single rule (i.e. "count the leading Revert"), instead of
requiring a set of rules (i.e. "if it begins with Reapply, then that
is reverted twice, count Reapply, multiply by two, and then add the
number of Revert").

I personally prefer a format that conveys how things happened in a
way that can be easily understood, over a format that looks pretty
on surface but needs more special cases to understand what led to
the outcome it represents.  But because reverting a commit ought to
be a rare event, and reverting a revert (or doing so recursively for
more levels) ought to be even rarer, it shouldn't matter all that
much either way how we phrase the reversion of a revert, or reversion
of such a reversion.

There will be folks who will complain no matter how we change the
way we phrase the reversion of a revert, while there may also be
other folks who like the change we make, and I feel that it would
not be worth my time to deal with the complaints for _this_
particular change that was proposed.  As long as proponents for this
change promise to handle all such complaints on and off list, I am
fine with the change, though.

Having said all that, I think this change, if we were to apply,
should be described in the documentation.  Perhaps something along
this line?

diff --git c/Documentation/git-revert.txt w/Documentation/git-revert.txt
index d2e10d3dce..d09311dd8a 100644
--- c/Documentation/git-revert.txt
+++ w/Documentation/git-revert.txt
@@ -31,6 +31,13 @@ both will discard uncommitted changes in your working directory.
 See "Reset, restore and revert" in linkgit:git[1] for the differences
 between the three commands.
 
+The command by default gives "Revert '<title>'" as the title to the
+resulting commit when reverting the original commit whose title is
+'<title>'.  A commit that reverts such a reversion commit is given
+"Reapply '<title>' as its title.  These can of course be edited in
+the editor when the reason for reverting is described.
+
+
 OPTIONS
 -------
 <commit>...::





[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]

  Powered by Linux