Files
nix/home/common/programs/git/scripts/git-cleanup
T
Miguel Palhas a436a816b6 git scripts
2024-10-06 14:36:09 +01:00

11 lines
211 B
Bash
Executable File

#!/usr/bin/env bash
# prune remote branches
git remote prune origin
git branch -r |\
awk '{print $1}' |\
grep -v -f /dev/fd/0 <(git branch -vv | grep origin) |\
awk '{print $1}' |\
xargs git branch -D