summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorGreyXor2023-12-30 16:52:42 +0100
committerGreyXor2023-12-30 16:52:42 +0100
commitd3610cab434b9165e8bfe760e0371afb537e7908 (patch)
treeeaf367d991cd38aac640a1e98126804aa3d025d4
parent7246e462dfd20ee931bf40cf5ca8cd5f9ce777dc (diff)
downloadaur-swaylock-git.tar.gz
refactor: new pkgver format
-rw-r--r--.SRCINFO3
-rw-r--r--PKGBUILD49
2 files changed, 26 insertions, 26 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 8a6556775490..6377cfe11dd8 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,6 +1,6 @@
pkgbase = swaylock-git
pkgdesc = Screen locker for Wayland (git development version)
- pkgver = r317.91bb968
+ pkgver = 1.7.2.r18.g91bb968
pkgrel = 1
url = https://github.com/swaywm/swaylock
arch = x86_64
@@ -18,7 +18,6 @@ pkgbase = swaylock-git
depends = libxkbcommon
provides = swaylock
conflicts = swaylock
- backup = etc/pam.d/swaylock
source = swaylock-git::git+https://github.com/swaywm/swaylock.git
b2sums = SKIP
diff --git a/PKGBUILD b/PKGBUILD
index b21118bd170c..6daca58f3214 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,46 +1,47 @@
# Maintainer: GreyXor <greyxor@protonmail.com>
# Contributor: Primalmotion <primalmotion@pm.me>
# Contributor: gilbus <aur@tinkershell.eu>
-
pkgname=swaylock-git
-pkgver=r317.91bb968
+pkgver=1.7.2.r18.g91bb968
pkgrel=1
pkgdesc='Screen locker for Wayland (git development version)'
-url='https://github.com/swaywm/swaylock'
-license=('MIT')
-provides=("${pkgname%-git}")
-conflicts=("${pkgname%-git}")
arch=('x86_64')
+url="https://github.com/swaywm/swaylock"
+license=("MIT")
depends=(
- "cairo"
- "gdk-pixbuf2"
- "glib2"
- "glibc"
- "pam"
- "wayland"
- "libxkbcommon"
+"cairo"
+"gdk-pixbuf2"
+"glib2"
+"glibc"
+"pam"
+"wayland"
+"libxkbcommon"
)
makedepends=(
- "git"
- "meson"
- "scdoc"
- "wayland-protocols"
+"git"
+"meson"
+"scdoc"
+"wayland-protocols"
)
-backup=('etc/pam.d/swaylock')
-source=("${pkgname}::git+https://github.com/swaywm/swaylock.git")
+provides=("${pkgname%-git}")
+conflicts=("${pkgname%-git}")
+source=("${pkgname}::git+${url}.git")
b2sums=('SKIP')
pkgver() {
- # Calculate the version dynamically using git information
- printf "r%s.%s" "$(git -C "$srcdir/${pkgname}" rev-list --count HEAD)" "$(git -C "$srcdir/${pkgname}" rev-parse --short HEAD)"
+ cd "$pkgname"
+
+ git describe --long --tags | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g'
}
build() {
- arch-meson build "${pkgname}"
- meson compile -C build
+ arch-meson "$pkgname" build
+ meson compile -C build
}
package() {
meson install -C build --destdir "$pkgdir"
- install -Dm644 "${pkgname}/LICENSE" "$pkgdir/usr/share/licenses/${pkgname}/LICENSE"
+
+ install -Dm644 "${pkgname}/LICENSE" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
+ install -Dm644 "${pkgname}/README.md" "${pkgdir}/usr/share/doc/${pkgname}/README.md"
}