Re: [PATCH] Make sure diff-helper can tell rename/copy in the new diff-raw format.
- From
Linus Torvalds <torvalds@osdl.org>
- Date
- May 23, 2005, 19:16 UTC
- Message-ID
- <Pine.LNX.4.58.0505231210420.2307@ppc970.osdl.org>
- In-Reply-To
- <Pine.LNX.4.58.0505231156210.2307@ppc970.osdl.org>
On Mon, 23 May 2005, Linus Torvalds wrote:
> > because having it there makes it just easier to parse, and means that we > can add "reasons" later without having to worry about ambiguities with > filenames.
Btw, putting the "what happened" into the fixed-format stuff before the filenames allows you to have more thana fixed number of filenames even in the machine-readable format. For example, it would allow the machine-readable format to have just a single NUL character at the end of the line for the "modified" case, since now it's unambigious where the line ends (thanks to the fact that "M" always has only one file).
Similarly, it allows us to later add a "combine" reason (take two files, combine them into a third), which needs three filenames. That would becomes very messy if the "reason" part is after the filenames, because it gets easily ambigious.
Linus