From 9a71047dd11bdfd1eaca029c96d0ac35393bc5ad Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Fri, 7 Dec 2012 08:20:54 -0500 Subject: [PATCH] posts:git:notes: mention `git remote prune` --- posts/Git/notes.org | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/posts/Git/notes.org b/posts/Git/notes.org index 85e1993..c134b98 100644 --- a/posts/Git/notes.org +++ b/posts/Git/notes.org @@ -1426,6 +1426,18 @@ Combining these into one command using Bash's command substitution: : $ git tag junio-gpg-pub $(git hash-object -w my-file) +** Prune remote tracking branches + +Sometimes an upstream remote will remove branches, and you'll be left +with stale remote-tracking branches. You can clean them up with +=remote prune=: + + : $ git remote prune origin + : Pruning origin + : URL: git://git.kernel.org/pub/scm/git/git.git + : * [pruned] origin/html + : * [pruned] origin/man + * Troubleshooting ** Git commit hangs with no output -- 2.26.2