On Tue, Jun 19, 2007 at 01:55:24AM +0100, Johannes Schindelin wrote: > Hi, > > On Mon, 18 Jun 2007, Frank Lichtenheld wrote: > > > Note the FIXME. Does anyone remember the reason why --get-regexp > > and --list use different output format? > > AFAIK --list was meant as a replacement to git-var --list. Thus, it had to > behave exactly the same. > > As for the FIXME: If you have a config like this: > > [core] > Some = where > over > the = core.rainbow > > git-config -z would output something like this: > > core.some\0where\0core.over\0core.the\0core.rainbow\0 > > Right? No. At least not with my patch. As you noted that would be incredibly stupid and worthless. Instead we output something like core.some\nwhere\0core.over\0core.the\ncore.rainbow\0 So you just can split on \0 and then split on \n. If there is no \n between two \0, you have a key without value. Gruesse, -- Frank Lichtenheld <frank@xxxxxxxxxxxxxx> www: http://www.djpig.de/ - To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html