diff options
author | Sean Whitton <spwhitton@spwhitton.name> | 2019-08-13 18:13:58 +0100 |
---|---|---|
committer | Sean Whitton <spwhitton@spwhitton.name> | 2019-08-13 18:13:58 +0100 |
commit | e4fe35831d1a5688fa8c8b6324f8aa57bc4edec2 (patch) | |
tree | cf2d905e96412b9447c559606e893afe82679dfe /bin/git-pull-safe | |
parent | 74c30472dd96d7e1502268bfb41720ebaeebfec7 (diff) | |
download | dotfiles-e4fe35831d1a5688fa8c8b6324f8aa57bc4edec2.tar.gz |
git-pull-safe: prune remote branches
Diffstat (limited to 'bin/git-pull-safe')
-rwxr-xr-x | bin/git-pull-safe | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/bin/git-pull-safe b/bin/git-pull-safe index 1750230e..dbe696d2 100755 --- a/bin/git-pull-safe +++ b/bin/git-pull-safe @@ -26,7 +26,7 @@ current_branch="$(git rev-parse --abbrev-ref HEAD)" branches="$(git for-each-ref --format='%(refname:short)' refs/heads/)" # (1) normal git branches -git remote update +git remote update --prune for branch in $branches; do remote="$(branch_remote $branch 2>/dev/null || true)" if [ "$(branch_prefix $branch)" != "dgit" ] && [ "$remote" != "" ]; then |