Tmux config with per-pane git branch/worktree display.
ln -sf ~/Helpers/tmux/.tmux.conf ~/.tmux.confReload an existing tmux session:
tmux source-file ~/.tmux.confgit config --global rebase.updateRefs true
git config --global rerere.enabled truerebase.updateRefs true- Update branch references when rebasing. See here for more informationrerere.enabled true- Enable Reuse Recorded Resolution. See here for more information
cd
git clone git@github.com:krazykeith/Helpers.git
chmod +x ~/Helpers/git-commands/*
echo 'export PATH="$HOME/Helpers/git-commands:$PATH"' >> ~/.zshrc
source ~/.zshrcThe below command will delete all local branches which no longer exist on remote.
git branch -v | grep '\[gone\]' | awk '{print $1}' | xargs git branch -Dgit branch -v- List all branches with their last commit messagegrep '\[gone\]'- Filter out branches which no longer exist on remoteawk '{print $1}'- Extract branch namexargs git branch -D- Delete the branch