Re: [PATCH 3/7] worktree move: new command

2018-02-14 Thread Junio C Hamano
Duy Nguyen writes: > On Wed, Feb 14, 2018 at 10:16 AM, Jeff King wrote: >> Hmm. That is not too bad, but somehow it feels funny to me to be >> polluting each test script with these annotations. And to be driving it >> from inside the test scripts. >> >> It

Re: [PATCH 3/7] worktree move: new command

2018-02-14 Thread Duy Nguyen
On Wed, Feb 14, 2018 at 10:16 AM, Jeff King wrote: > Hmm. That is not too bad, but somehow it feels funny to me to be > polluting each test script with these annotations. And to be driving it > from inside the test scripts. > > It seems like: > > make SANITIZE=leak test

Re: [PATCH 3/7] worktree move: new command

2018-02-13 Thread Jeff King
On Tue, Feb 13, 2018 at 07:27:58AM +0700, Duy Nguyen wrote: > > Makes sense to try to make sure that we don't regress leak-free tests. I > > don't know what our Travis-budget looks like, but I would volunteer to > > run something like this periodically using my own cycles. > > > > My experience

Re: [PATCH 3/7] worktree move: new command

2018-02-12 Thread Duy Nguyen
On Mon, Feb 12, 2018 at 11:15:06PM +0100, Martin Ågren wrote: > On 12 February 2018 at 10:56, Duy Nguyen wrote: > > On Wed, Feb 7, 2018 at 3:05 AM, Martin Ågren wrote: > >> On 6 February 2018 at 03:13, Jeff King wrote: > >>> On Mon, Feb

Re: [PATCH 3/7] worktree move: new command

2018-02-12 Thread Martin Ågren
On 12 February 2018 at 10:56, Duy Nguyen wrote: > On Wed, Feb 7, 2018 at 3:05 AM, Martin Ågren wrote: >> On 6 February 2018 at 03:13, Jeff King wrote: >>> On Mon, Feb 05, 2018 at 08:28:10PM +0700, Duy Nguyen wrote: I learned

Re: [PATCH 3/7] worktree move: new command

2018-02-12 Thread Duy Nguyen
On Wed, Feb 7, 2018 at 3:05 AM, Martin Ågren wrote: > On 6 February 2018 at 03:13, Jeff King wrote: >> On Mon, Feb 05, 2018 at 08:28:10PM +0700, Duy Nguyen wrote: >>> I learned SANITIZE=leak today! It not only catches this but also "dst". >>> >>> Jeff is

Re: [PATCH 3/7] worktree move: new command

2018-02-06 Thread Martin Ågren
On 6 February 2018 at 03:13, Jeff King wrote: > On Mon, Feb 05, 2018 at 08:28:10PM +0700, Duy Nguyen wrote: >> I learned SANITIZE=leak today! It not only catches this but also "dst". >> >> Jeff is there any ongoing effort to make the test suite pass with >> SANITIZE=leak? My t2038

Re: [PATCH 3/7] worktree move: new command

2018-02-05 Thread Jeff King
On Mon, Feb 05, 2018 at 08:28:10PM +0700, Duy Nguyen wrote: > >> This is still leaking 'worktrees'[1]. You probably want > >> free_worktrees() immediately after the find_worktree() invocation. > > > > Sorry, free_worktrees() after the last use of 'wt' since you still > > need to access its

Re: [PATCH 3/7] worktree move: new command

2018-02-05 Thread Duy Nguyen
On Fri, Feb 2, 2018 at 6:23 PM, Eric Sunshine wrote: > On Fri, Feb 2, 2018 at 4:15 AM, Eric Sunshine wrote: >> On Wed, Jan 24, 2018 at 4:53 AM, Nguyễn Thái Ngọc Duy >> wrote: >>> +static int move_worktree(int ac, const char

Re: [PATCH 3/7] worktree move: new command

2018-02-02 Thread Eric Sunshine
On Fri, Feb 2, 2018 at 4:15 AM, Eric Sunshine wrote: > On Wed, Jan 24, 2018 at 4:53 AM, Nguyễn Thái Ngọc Duy > wrote: >> +static int move_worktree(int ac, const char **av, const char *prefix) >> +{ >> + [...] >> + worktrees =

Re: [PATCH 3/7] worktree move: new command

2018-02-02 Thread Eric Sunshine
On Wed, Jan 24, 2018 at 4:53 AM, Nguyễn Thái Ngọc Duy wrote: > This command allows to relocate linked worktrees. Main worktree cannot > (yet) be moved. > [...] > Signed-off-by: Nguyễn Thái Ngọc Duy > --- > diff --git a/Documentation/git-worktree.txt

[PATCH 3/7] worktree move: new command

2018-01-24 Thread Nguyễn Thái Ngọc Duy
This command allows to relocate linked worktrees. Main worktree cannot (yet) be moved. There are two options to move the main worktree, but both have complications, so it's not implemented yet. Anyway the options are: - convert the main worktree to a linked one and move it away, leave the git