summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorFilip Parag2020-08-23 00:12:04 +0200
committerFilip Parag2020-08-23 00:12:04 +0200
commitd59ced853d5ff06b381aeedb1bce9e196e147c04 (patch)
tree52c0dce2e00367b9c6a1f8c818d5b74af86ade42
parent4bd3aa56e9849b38d7ae2087ef42807210930e3d (diff)
downloadaur-d59ced853d5ff06b381aeedb1bce9e196e147c04.tar.gz
better versioning
-rw-r--r--.SRCINFO2
-rw-r--r--PKGBUILD22
2 files changed, 17 insertions, 7 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 43c663fb946..715bc8a4a34 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,7 +1,7 @@
pkgbase = wmrc
pkgdesc = WMRC is a shell utility for extending window manager capabilities using modules with dependency and error checking.
pkgver = 1.1
- pkgrel = 3
+ pkgrel = 4
url = https://github.com/filiparag/wmrc
arch = any
license = MIT
diff --git a/PKGBUILD b/PKGBUILD
index acd464b27d8..3991de56796 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -2,7 +2,7 @@
pkgname=wmrc
pkgver=1.1
-pkgrel=3
+pkgrel=4
pkgdesc='WMRC is a shell utility for extending window manager capabilities using modules with dependency and error checking.'
arch=('any')
url='https://github.com/filiparag/wmrc'
@@ -12,12 +12,22 @@ makedepends=('git')
source=('git+https://github.com/filiparag/wmrc.git')
sha1sums=('SKIP')
+prepare() {
+ cd "${pkgname}"
+ git checkout "tags/${pkgver}"
+}
+
+pkgver() {
+ cd "${pkgname}"
+ git describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g'
+}
+
package() {
cd "${pkgname}"
- install -Dm 775 "${pkgname}" "${pkgdir}/usr/bin/${pkgname}"
- install -d -m 775 "${pkgdir}/usr/share/${pkgname}"
- install -Dm 664 "rc.conf" "${pkgdir}/usr/share/${pkgname}/"
- install -Dm 664 "usage.txt" "${pkgdir}/usr/share/${pkgname}/"
- install -Dm 664 "wmrc.man" "${pkgdir}/usr/share/man/man1/${pkgname}.${pkgver}"
+ install -Dm 755 "${pkgname}" "${pkgdir}/usr/bin/${pkgname}"
+ install -d -m 755 "${pkgdir}/usr/share/${pkgname}"
+ install -Dm 644 "rc.conf" "${pkgdir}/usr/share/${pkgname}/"
+ install -Dm 644 "usage.txt" "${pkgdir}/usr/share/${pkgname}/"
+ install -Dm 644 "wmrc.man" "${pkgdir}/usr/share/man/man1/${pkgname}.${pkgver}"
cp -r --preserve=mode "modules" "${pkgdir}/usr/share/${pkgname}/"
} \ No newline at end of file