diff options
author | Patrick Spek <p.spek@tyil.nl> | 2024-07-02 09:53:50 +0200 |
---|---|---|
committer | Patrick Spek <p.spek@tyil.nl> | 2024-07-02 09:53:50 +0200 |
commit | ffcaf7ff76ba26b60223e64bee9daf80e2e8d4dd (patch) | |
tree | 142efdb5d4a36bc1d3c3dee1d75b09956a1bc0e5 | |
parent | 195453a0714e8c6502d213df21184bfa2a095642 (diff) |
Resolved bug with read call, and it now also ignores main as a branch
since people have found it necesary to break decades of backwards
compatibility for some dumb American-centric virtue signalling that
makes no sense to anyone with an IQ above 20.
-rwxr-xr-x | .local/bin/git-branch-cleanup | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/.local/bin/git-branch-cleanup b/.local/bin/git-branch-cleanup index 5e86714..555ac0c 100755 --- a/.local/bin/git-branch-cleanup +++ b/.local/bin/git-branch-cleanup @@ -1,4 +1,4 @@ -#! /usr/bin/env sh +#!/bin/sh main() { @@ -16,6 +16,7 @@ main() git branch --merged \ | awk '{ print $NF }' \ | grep -Ev "^master$" \ + | grep -Ev "^main$" \ > "$buffer" count=$(wc -l < "$buffer") @@ -30,7 +31,7 @@ main() cat -- "$buffer" printf "\n^C to cancel...\n" - read + read _ while read -r branch do |