Re: [PATCH v2] worktree: list operation

2015-08-09 Thread Eric Sunshine
Thanks for the patch. Comments below... On Sat, Aug 8, 2015 at 8:19 PM, Michael Rappazzo wrote: > worktree: list operation Imperative mood: worktree: add 'list' command > 'git worktree list' will list the main worktree followed by any linked > worktrees which were created using 'git worktr

Re: [PATCH v2] worktree: list operation

2015-08-08 Thread Andreas Schwab
Michael Rappazzo writes: > @@ -36,7 +37,7 @@ static int prune_worktree(const char *id, struct strbuf > *reason) > fd = open(git_path("worktrees/%s/gitdir", id), O_RDONLY); > if (fd < 0) { > strbuf_addf(reason, _("Removing worktrees/%s: unable to read > gitdir file (%s)

[PATCH v2] worktree: list operation

2015-08-08 Thread Michael Rappazzo
I am attempting to add the 'git worktree list' command. I don't have a lot of c experience, so please double check that I am not missing something important. Sorry about publishing the first version too soon. Michael Rappazzo (1): worktree: list operation Documentation/git-worktree.txt |

[PATCH v2] worktree: list operation

2015-08-08 Thread Michael Rappazzo
'git worktree list' will list the main worktree followed by any linked worktrees which were created using 'git worktree add'. The option '--main-only' will restrict the list to only the main worktree. --- Documentation/git-worktree.txt | 9 - builtin/worktree.c | 84 +