From: Linus Arver Date: Thu, 10 Aug 2023 21:50:59 GMT Subject: Re: [PATCH v3 2/2] doc: revert: add discussion Message-ID: In-Reply-To: <20230809171531.2564807-2-oswald.buddenhagen@gmx.de> Oswald Buddenhagen writes: > while thinking about what to write, i came up with an idea for another > improvement: with (implicit) --edit, the template message would end up > being: > > This reverts commit , > because . This sounds great to me. Nit: the "doc: revert: add discussion" subject line should probably be more like "revert doc: suggest adding the 'why' behind reverts". > --- > Documentation/git-revert.txt | 10 ++++++++++ > 1 file changed, 10 insertions(+) > > diff --git a/Documentation/git-revert.txt b/Documentation/git-revert.txt > index d2e10d3dce..2b52dc89a8 100644 > --- a/Documentation/git-revert.txt > +++ b/Documentation/git-revert.txt > @@ -142,6 +142,16 @@ EXAMPLES > changes. The revert only modifies the working tree and the > index. > > +DISCUSSION > +---------- > + > +While git creates a basic commit message automatically, you really > +should not leave it at that. In particular, it is _strongly_ > +recommended to explain why the original commit is being reverted. > +Repeatedly reverting reversions yields increasingly unwieldy > +commit subjects; latest when you arrive at 'Reapply "Reapply > +"""' you should get creative. The word "latest" here sounds odd. Ditto for "get creative". How about the following rewording? While git creates a basic commit message automatically, it is _strongly_ recommended to explain why the original commit is being reverted. In addition, repeatedly reverting the same commit will result in increasingly unwieldy subject lines, for example 'Reapply "Reapply """'. Please consider rewording such subject lines to reflect the reason why the original commit is being reapplied again.