From 1fd2c730d946c002b7757399a303e2fdfe95edf6 Mon Sep 17 00:00:00 2001 From: druckdev Date: Fri, 12 Nov 2021 14:32:01 +0100 Subject: [PATCH] git:alias:track: Do not print trailing arrow Do not print trailing arrow when the local branch is not tracking a remote branch. --- .config/git/config | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.config/git/config b/.config/git/config index b177990..df4f8e3 100644 --- a/.config/git/config +++ b/.config/git/config @@ -16,7 +16,7 @@ [alias] root = rev-parse --show-toplevel spull = "!__git_spull() { git pull \"$@\" && git submodule sync --recursive && git submodule update --init --recursive; }; __git_spull" - track = "!track() { git for-each-ref --format='%(upstream:short) <- %(refname:short)' refs/heads | sort | awk '{ print $3,$2,$1}' | column -t; }; track" + track = "!track() { git for-each-ref --format='%(upstream:short) <- %(refname:short)' refs/heads | sort | awk '{ print $3,$2,$1}' | column -t | sed 's/ *<- *$//'; }; track" [status] submodulesummary = true [diff]