]> git.sev.monster Git - abchr.git/blobdiff - apkgvers
apkgvers: replace grep/sed with awk
[abchr.git] / apkgvers
index 135f0a6644ff11d0c24e2912ecff8ab2e909fc5a..51256cee759aeb6cce09db71675773a0d359d3bd 100755 (executable)
--- a/apkgvers
+++ b/apkgvers
@@ -1,3 +1,3 @@
 #!/bin/sh
 if ! which column >/dev/null 2>&1; then echo need column command >&2; exit 1; fi
-grep pkgver= */APKBUILD | sort | sed -e 's_/APKBUILD:pkgver=_ _' | column -tNname,version -R1
+awk 'match($0, /pkgver="?([^" ;]*)/, m) {gsub("/APKBUILD$", "", FILENAME); print FILENAME, m[1]}' */APKBUILD | sort | column -tNname,version -R1
This page took 0.029747 seconds and 4 git commands to generate.