[PATCH 1/6] templates: Fewer subprocesses in pre-commit hook

2013-06-10 Thread Richard Hartmann
Spawning a new subprocess for every line printed is inefficient. Thus spawn only one instance of `echo`. Signed-off-by: Richard Hartmann richih.mailingl...@gmail.com --- templates/hooks--pre-commit.sample | 24 1 file changed, 12 insertions(+), 12 deletions(-) diff

Re: [PATCH 1/6] templates: Fewer subprocesses in pre-commit hook

2013-06-10 Thread Junio C Hamano
Richard Hartmann richih.mailingl...@gmail.com writes: Spawning a new subprocess for every line printed is inefficient. Thus spawn only one instance of `echo`. Signed-off-by: Richard Hartmann richih.mailingl...@gmail.com --- templates/hooks--pre-commit.sample | 24

Re: [PATCH 1/6] templates: Fewer subprocesses in pre-commit hook

2013-06-10 Thread Richard Hartmann
Hi Junio, if you want a new patch, just say the word. Richard -- To unsubscribe from this list: send the line unsubscribe git in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH 1/6] templates: Fewer subprocesses in pre-commit hook

2013-06-10 Thread Jeff King
On Mon, Jun 10, 2013 at 08:36:00PM +0200, Richard Hartmann wrote: Spawning a new subprocess for every line printed is inefficient. Thus spawn only one instance of `echo`. Most modern shells have echo as a built-in these days, and do not fork at all to run it. E.g., try strace sh -c 'echo foo'