From: Nikolaj Shurkaev Date: Thu, 23 Feb 2012 12:19:17 GMT Subject: Re: git log -z doesn't separate commits with NULs Message-ID: <4F462EC5.6090007@gmail.com> In-Reply-To: Thank you. That really helped me. --- Nikolaj 23.02.2012 13:35, Andreas Schwab пишет: > Nikolaj Shurkaev writes: > >> I did something like this: >> git log -z --patch HEAD~10..HEAD -- SomePathHere | xargs -0 >> --max-chars=1000000 ~/1.sh >> >> If I put >> echo "started" >> into the file ~/1.sh I see that the file is called only once instead of >> multiple times. > If you want the command to be called once for each commit you need to > pass --max-args=1 to xargs. Otherwise xargs will cumulate the arguments > until --max-chars is reached, and the command is expected to loop over > them. > > Andreas. >