git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
* man page for "git-worktree" is a bit confusing WRT "prune"
@ 2017-11-13 14:48 Robert P. J. Day
  2017-11-13 17:39 ` Eric Sunshine
  0 siblings, 1 reply; 5+ messages in thread
From: Robert P. J. Day @ 2017-11-13 14:48 UTC (permalink / raw)
  To: Git Mailing list


  once more, into the man pages ... "git worktree" seems like a fairly
simple command, but there is some confusion about the function of

  $ git worktree prune

the normal meaning of "prune" (certainly with git commands) is to
actually delete some content, and the initial impression of this
command is that it will delete an actual worktree. however, further
reading reveals:

" ... or you can run git worktree prune in the main or any linked
working tree to clean up any stale administrative files."

  ah, so one learns that the subcommand "prune" does *not* do any
actual pruning as people would *normally* understand it, it simply
deletes the administrative information about an already-deleted
worktree, do i read that correctly?

  that's emphasized further down in the actual definition of "prune":

    prune
        Prune working tree information in $GIT_DIR/worktrees.

but perhaps that explanation could be extended to say it only works on
already-deleted trees, since that's certainly not clear from that
single sentence.

  finally, the prune "--expire" option is truly confusing:

    --expire <time>
        With prune, only expire unused working trees older than <time>.

suddenly, we encounter the verb "expire", which means ... what? how
does "expiring" a worktree differ from "pruning" a worktree? and what
makes a worktree "unused"? the normal meaning of "unused" is that you
haven't, you know, *used* it lately. in this context, though, does it
mean deleted? and if it means deleted, what does it mean for it to be
older than some time if it's already gone?

  thoughts?

rday

-- 

========================================================================
Robert P. J. Day                                 Ottawa, Ontario, CANADA
                        http://crashcourse.ca

Twitter:                                       http://twitter.com/rpjday
LinkedIn:                               http://ca.linkedin.com/in/rpjday
========================================================================

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2017-11-14  8:47 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-11-13 14:48 man page for "git-worktree" is a bit confusing WRT "prune" Robert P. J. Day
2017-11-13 17:39 ` Eric Sunshine
2017-11-13 21:06   ` Robert P. J. Day
2017-11-14  3:26     ` Eric Sunshine
2017-11-14  8:47       ` Robert P. J. Day

Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).