all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Andreas Schwab <schwab@linux-m68k.org>
To: Nathan Moreau <nathan.moreau@m4x.org>
Cc: Stephen Leake <stephen_leake@stephe-leake.org>,
	emacs-devel <emacs-devel@gnu.org>
Subject: Re: git: how to restore a deleted worktree?
Date: Sun, 07 Jan 2018 21:22:58 +0100	[thread overview]
Message-ID: <87k1wtv2ot.fsf@linux-m68k.org> (raw)
In-Reply-To: <CADDcBWXXDtExMPyxGU6ESKhNLqGR4n_JrBpgscenjPX01ozvwQ@mail.gmail.com> (Nathan Moreau's message of "Sun, 7 Jan 2018 21:15:44 +0100")

On Jan 07 2018, Nathan Moreau <nathan.moreau@m4x.org> wrote:

> To wrap things up, to discard a worktree you should:
> - remove the branch associated to it (you can find it out using the
> command `git worktree list --porcelain')

No, there is no need to remove the branch.  You cannot do that anyway as
long as it is checked out.

> - then run `git worktree prune'

> In particular, I recommand you **not** to remove the directory of the
> worktree manually,

No, that _is_ the right way to remove a worktree.

Andreas.

-- 
Andreas Schwab, schwab@linux-m68k.org
GPG Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."



  reply	other threads:[~2018-01-07 20:22 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-01-04 13:51 git: how to restore a deleted worktree? Stephen Leake
2018-01-04 14:06 ` Noam Postavsky
2018-01-04 22:04   ` Stephen Leake
2018-01-04 23:14     ` Andreas Schwab
2018-01-04 14:07 ` Nathan Moreau
2018-01-04 22:07   ` Stephen Leake
2018-01-07 20:15     ` Nathan Moreau
2018-01-07 20:22       ` Andreas Schwab [this message]
2018-01-04 14:49 ` Andreas Schwab
2018-01-04 18:29 ` Stefan Monnier

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87k1wtv2ot.fsf@linux-m68k.org \
    --to=schwab@linux-m68k.org \
    --cc=emacs-devel@gnu.org \
    --cc=nathan.moreau@m4x.org \
    --cc=stephen_leake@stephe-leake.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.