summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorVincent Grande2021-01-12 17:26:32 -0500
committerVincent Grande2021-01-12 17:26:32 -0500
commitbea0e3a13d56bca0dcb6eb4033088f9798aa624b (patch)
treeb2954f31da69a978af0e8607b37be795438dbd77
parent806b3d86694c93126f4c8130c752b10bfd3eb628 (diff)
downloadaur-bea0e3a13d56bca0dcb6eb4033088f9798aa624b.tar.gz
fix pkgver
-rw-r--r--PKGBUILD10
1 files changed, 9 insertions, 1 deletions
diff --git a/PKGBUILD b/PKGBUILD
index 836f25ba2a4..aafea46721c 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -14,9 +14,17 @@ conflicts=(libnsl)
source=("git+https://github.com/thkukuk/libnsl.git")
md5sums=('SKIP')
+_commit() {
+ # Convert HEAD into a shortened commit id:
+ git rev-parse --short HEAD
+}
+
pkgver() {
cd libnsl
- git describe --tags | sed 's/-/+/g'
+
+ # Suggestions for improvement welcome!
+ printf '%s.r%s.%s' \
+ "$(_commit)"
}
prepare() {