summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDave Reisner <dreisner@archlinux.org>2017-04-05 19:33:23 -0400
committerDave Reisner <dreisner@archlinux.org>2017-04-05 19:33:23 -0400
commitde80a09c157c2bb1ab626e44b160f3ffe0d67e0e (patch)
treeb5090dce2348dc561f2f4f37036deaf8fd7f1b3f
parent7beb3f9be3044ae37fae8848d8841e983f4f3415 (diff)
downloadasp32-de80a09c157c2bb1ab626e44b160f3ffe0d67e0e.tar.xz
remote: avoid need for awk post-processing
-rw-r--r--remote.inc.sh4
1 files changed, 2 insertions, 2 deletions
diff --git a/remote.inc.sh b/remote.inc.sh
index db6d318..01031e0 100644
--- a/remote.inc.sh
+++ b/remote.inc.sh
@@ -45,8 +45,8 @@ remote_is_tracking() {
remote_get_tracked_refs() {
local remote=$1
- mapfile -t "$2" < <(git for-each-ref --format='%(refname)' "refs/remotes/$1" |
- awk -F'/' -v "remote=$1" '{ print "packages/" $NF }')
+ mapfile -t "$2" < \
+ <(git for-each-ref --format='%(refname:strip=3)' "refs/remotes/$remote")
}
remote_update_refs() {