From: Jeff King Date: Thu, 23 Feb 2012 10:27:03 GMT Subject: Re: git log -z doesn't separate commits with NULs Message-ID: <20120223102702.GC2912@sigill.intra.peff.net> In-Reply-To: <4F460EB7.3030503@diamand.org> On Thu, Feb 23, 2012 at 10:02:31AM +0000, Luke Diamand wrote: > >Thus I suspect there is a but in git log -z command and that doesn't > >"Separate the commits with NULs instead of with new newlines." as > >promised in the documents. > >Is my understanding correct or I don't understand the documentation or > >somehow pass wrong parameters into git log? > > Just a guess, but doesn't the "--patch" option to git log ask it to > produce a patch output? Surely that will override the -z: patch will > not be expecting NULs. No. You will get the patch text and the log message together, with commits separated by NUL. Some diff output formats will also respect "-z" to produce NULs internally (e.g., "--raw" will use it to separate filenames), but "--patch" does not. -Peff