The status program will check local repos and their status, if they're up-to-date, if there are some scattered files in the worktree, if there are any branches that might have code I'm working on, etc.
To keep the entire git universe clean, It would be nice if status could also check the existence of branches on origin.
Solution (Partial)
Remote branches can be detected with
git branch -r
Note that any branches that have been deleted on remote will still remain on your system. You can "prune" them with:
git remote prune origin
If you want to just see which branches will be pruned, you can add the --dry-run flag:
Problem
The
status
program will check local repos and their status, if they're up-to-date, if there are some scattered files in the worktree, if there are any branches that might have code I'm working on, etc.To keep the entire git universe clean, It would be nice if
status
could also check the existence of branches onorigin
.Solution (Partial)
Remote branches can be detected with
Note that any branches that have been deleted on remote will still remain on your system. You can "prune" them with:
If you want to just see which branches will be pruned, you can add the
--dry-run
flag: