Re: [PATCHv13 5/7] git submodule update: have a dedicated helper for cloning

2016-02-19 Thread Stefan Beller
On Fri, Feb 19, 2016 at 11:08 AM, Jeff King wrote: > On Fri, Feb 19, 2016 at 12:20:48PM -0500, Eric Sunshine wrote: > >> >>> + argv_array_pushl(>args, "--path", sub->path, NULL); >> >>> + argv_array_pushl(>args, "--name", sub->name, NULL); >> >>> +

Re: [PATCHv13 5/7] git submodule update: have a dedicated helper for cloning

2016-02-19 Thread Jeff King
On Fri, Feb 19, 2016 at 12:20:48PM -0500, Eric Sunshine wrote: > >>> + argv_array_pushl(>args, "--path", sub->path, NULL); > >>> + argv_array_pushl(>args, "--name", sub->name, NULL); > >>> + argv_array_pushl(>args, "--url", strdup(url), NULL); > >> > >> No need

Re: [PATCHv13 5/7] git submodule update: have a dedicated helper for cloning

2016-02-19 Thread Eric Sunshine
On Fri, Feb 19, 2016 at 11:47 AM, Stefan Beller wrote: > On Fri, Feb 19, 2016 at 4:03 AM, Jeff King wrote: >> On Thu, Feb 18, 2016 at 03:33:16PM -0800, Stefan Beller wrote: >> >>> + if (needs_cloning) { >>> + cp->git_cmd = 1; >>> +

Re: [PATCHv13 5/7] git submodule update: have a dedicated helper for cloning

2016-02-19 Thread Stefan Beller
On Fri, Feb 19, 2016 at 4:03 AM, Jeff King wrote: > On Thu, Feb 18, 2016 at 03:33:16PM -0800, Stefan Beller wrote: > >> + if (needs_cloning) { >> + cp->git_cmd = 1; >> + cp->no_stdin = 1; >> + cp->stdout_to_stderr = 1; >> +

Re: [PATCHv13 5/7] git submodule update: have a dedicated helper for cloning

2016-02-19 Thread Jeff King
On Thu, Feb 18, 2016 at 03:33:16PM -0800, Stefan Beller wrote: > + if (needs_cloning) { > + cp->git_cmd = 1; > + cp->no_stdin = 1; > + cp->stdout_to_stderr = 1; > + cp->err = -1; > + argv_array_push(>args, "submodule--helper"); > +

[PATCHv13 5/7] git submodule update: have a dedicated helper for cloning

2016-02-18 Thread Stefan Beller
This introduces a new helper function in git submodule--helper which takes care of cloning all submodules, which we want to parallelize eventually. Some tests (such as empty URL, update_mode=none) are required in the helper to make the decision for cloning. These checks have been moved into the C