Re: [PATCH v4 1/4] rebase: start implementing it as a builtin

2018-07-22 Thread Duy Nguyen
On Sun, Jul 8, 2018 at 8:03 PM Pratik Karki wrote: > +int cmd_rebase(int argc, const char **argv, const char *prefix) > +{ > + /* > +* NEEDSWORK: Once the builtin rebase has been tested enough > +* and git-legacy-rebase.sh is retired to contrib/, this preamble > +*

Re: [PATCH v4 1/4] rebase: start implementing it as a builtin

2018-07-09 Thread Pratik Karki
Hi, On Mon, Jul 9, 2018 at 2:21 PM Eric Sunshine wrote: > > On Mon, Jul 9, 2018 at 3:59 AM Andrei Rybak wrote: > > On 2018-07-08 20:01, Pratik Karki wrote: > > > +static int use_builtin_rebase(void) > > > +{ > > > + struct child_process cp = CHILD_PROCESS_INIT; > > > + struct strbuf out

Re: [PATCH v4 1/4] rebase: start implementing it as a builtin

2018-07-09 Thread Eric Sunshine
On Mon, Jul 9, 2018 at 3:59 AM Andrei Rybak wrote: > On 2018-07-08 20:01, Pratik Karki wrote: > > +static int use_builtin_rebase(void) > > +{ > > + struct child_process cp = CHILD_PROCESS_INIT; > > + struct strbuf out = STRBUF_INIT; > > + int ret; > > + > > + argv_array_pushl(, >

Re: [PATCH v4 1/4] rebase: start implementing it as a builtin

2018-07-09 Thread Andrei Rybak
On 2018-07-08 20:01, Pratik Karki wrote: > + > +static int use_builtin_rebase(void) > +{ > + struct child_process cp = CHILD_PROCESS_INIT; > + struct strbuf out = STRBUF_INIT; > + int ret; > + > + argv_array_pushl(, > + "config", "--bool", "rebase.usebuiltin",

[PATCH v4 1/4] rebase: start implementing it as a builtin

2018-07-08 Thread Pratik Karki
This commit imitates the strategy that was used to convert the difftool to a builtin. We start by renaming the shell script `git-rebase.sh` to `git-legacy-rebase.sh` and introduce a `builtin/rebase.c` that simply executes the shell script version, unless the config setting `rebase.useBuiltin` is