[PATCH 1 of 2] commit: save commit message so it's not destroyed by rollback

Adrian Buehlmann adrian at cadifra.com
Sun Nov 22 17:14:30 CST 2009

On 22.11.2009 22:21, Gilles Moris wrote:
> On Sunday 22 November 2009 07:11:12 pm Greg Ward wrote:
>> Rationale: if a pretxncommit hook rejects this commit, the transaction
>> is rolled back and the user's commit message is irrevocably lost.
>> So save a copy in .hg/message, just in case.  Also handy if the user
>> deliberately rolls back a commit in order to amend it.
> I would also use the .txt suffix for the message filename as Adrian Buehlmann 
> suggested previously, especially if we want to advertise the file presence in 
> patch #2. This will make Windows users life easier.


.hg/message is perfect (without .txt)

More information about the Mercurial-devel mailing list