git:track: Fix unnecessary subshell launch
While at it, modify the formatting of the line above slightly.
This commit is contained in:
@@ -22,9 +22,8 @@ git for-each-ref --format='%(upstream),%(refname)' refs/heads "${@/#/refs/remote
|
||||
s:,/:,:g
|
||||
s:(^|\n)([^,]+),\n\2:\1\2:g
|
||||
s:(^|\n)([^/,]*)([^\n]*\n\2(,|/))*:\n,\n&:g
|
||||
s:\n,\n+$:\n:
|
||||
' \
|
||||
| (echo remote,local; cat) \
|
||||
s:\n,\n+$:\n:' \
|
||||
| { echo remote,local; cat; } \
|
||||
| sed -E 's:(.*),(.*):\2,\1:g; s:^,: ,:; s:,$:, :' \
|
||||
| column -ts, \
|
||||
| sed '2d; 1{p;s/./―/g}'
|
||||
|
||||
Reference in New Issue
Block a user