Thread (37 messages) flat view 37 messages, 2 authors, 2016-06-15

Re: [PATCH v2 13/23] worktree: introduce "add" command

From: Eric Sunshine <hidden>
Date: 2016-06-15 23:05:39

On Fri, Jul 3, 2015 at 10:53 PM, Duy Nguyen [off-list ref] wrote:
On Sat, Jul 4, 2015 at 7:17 AM, Eric Sunshine [off-list ref] wrote:
quoted
 COMMANDS
 --------
+add <path> <branch>::
+
+Check out `<branch>` into a separate working directory, `<path>`, creating
+`<path>` if necessary. The new working directory is linked to the current
+repository, sharing everything except working directory specific files
+such as HEAD, index, etc. If `<path>` already exists, it must be empty.
Side note, "must be empty" is an implementation limitation. I think
the two-way merge employed by git-checkout can deal with dirty <path>
and only perform the checkout if there is no data loss. But we can
leave this for later.
Perhaps we should omit the bit about an existing but empty directory
for now? Like this:

    Create `<path>` and checkout `<branch>` into it. The new working
    directory is linked to the current repository, sharing everything
    except working directory specific files such as HEAD, index, etc.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help