dotfiles
shell, editor, ssh.
git clone https://owenrusk.dev/dotfiles.git
commit c9ff59a75208df34ebe0908f8c55df840db0d38e parent a7367668da06dca57008f85a9a009e71c89e756b author Owen Rusk <owen@papermothgames.com> date 2026-09-17 16:15:28 -0500
srcstat: show the branch too
| bin/srcstat | +2 | -1 |
diff --git a/bin/srcstat b/bin/srcstat index 15709b5..710dc7d 100755 --- a/bin/srcstat +++ b/bin/srcstat @@ -5,8 +5,9 @@ src=${SRC:-$HOME/src} for dir in "$src"/*/; do [ -d "$dir.git" ] || continue name=$(basename "$dir") + branch=$(git -C "$dir" branch --show-current) changed=$(git -C "$dir" status --porcelain | wc -l | tr -d ' ') ahead=$(git -C "$dir" rev-list --count '@{upstream}..HEAD' 2>/dev/null || echo -) [ "$changed" = 0 ] && [ "$ahead" = 0 ] && continue- printf '%-24s %4s changed %4s ahead\n' "$name" "$changed" "$ahead"+ printf '%-24s %-16s %4s changed %4s ahead\n' "$name" "$branch" "$changed" "$ahead" done