On 02/24/2014 12:37 PM, Darshit Shah wrote: >>> Based on the test that is failing, can you please show the output of: >>> >>> git submodule --quiet foreach echo 'a b' '"c d"'
>> What about: >> >> git submodule --quiet foreach 'echo a b "c d" "$sha1"' >> > > The first command: > git submodule --quiet foreach echo 'a b' '"c d"' > gives the output: a b "c d" Good, I was right - newer git is doing one less round of shell interpolation, so the second layer of quotes that we were adding for older git now show up as literal arguments in newer git. > Where there is a double space between a and b while c and d still retain > their quotes. > > The second command: > git submodule --quiet foreach 'echo a b "c d" "$sha1"' > > Gives the output: > a b c d 0ac90c5a98030c998f3e1db3a0d7f19d4630b6b6 Yay - you confirmed that the solution that works for both versions of git is to ensure that we provide exactly one argument to the foreach command, where that argument gets passed through the shell with identical results. I'll patch maint.mk shortly. -- Eric Blake eblake redhat com +1-919-301-3266 Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature