Re: Extra metadata in the commit?
- From
Alex Riesen <raa.lkml@gmail.com>
- Date
- Apr 25, 2009, 09:49 UTC
- Message-ID
- <81b0412b0904250249k717ae07did24867bd6ca6e8a2@mail.gmail.com>
- In-Reply-To
- <alpine.DEB.1.00.0904250154080.10279@pacific.mpi-cbg.de>
2009/4/25 Johannes Schindelin <Johannes.Schindelin@gmx.de>:
Show 15 quoted lines
> On Fri, 24 Apr 2009, Scott Chacon wrote: > >> I'm working on a hg<->git bidirectional tool using Git as the >> communication protocol, so there is a bunch of Hg metadata that I need >> to keep in Git to ensure I can convert commits created in Hg back into >> the exact same objects after they upload to the Git db and then come >> back down. This means storing explicit rename info, branch names, etc >> somewhere without messing up Git clients that want to work on the same >> repo. So, I can keep this data in the commit message, but I thought it >> would be cleaner to keep it as extra fields in the commit object before >> the "\n\n" separator. > > I'd suggest keeping it in the commit body, for better visibility and > easier handling by tools. >
BTW, by the same convention we treat the very first line of a commit message specially, we can say that the last line, if non-empty (IOW, does not end with \n), is treated specially by UI tools (grayed out, for example):
Subject\n \n Body\n \n something:very:special