summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: caa46b6364cc8a3e5325e54a9404ed2ce36824a4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
# Maintainer: GreyXor <greyxor@protonmail.com>
# Contributor: Drew DeVault <sir@cmpwn.com>
# Contributor: Antonin Décimo <antonin dot decimo at gmail dot com>

pkgname=sway-contrib-git
pkgver=r6.c6f601b
pkgrel=1
arch=('x86_64')
pkgdesc='A collection of user-contributed scripts for sway'
url='https://swaywm.org/'
license=('MIT')
depends=(
    "sway"
    "python-i3ipc"
    "grim"
    "slurp"
    "wl-clipboard"
    "jq"
    "libnotify"
)
makedepends=("git")
provides=("${pkgname%-git}")
conflicts=("${pkgname%-git}")
source=("${pkgname}::git+https://github.com/OctopusET/sway-contrib.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)"
}

package() {
  cd "$srcdir/${pkgname}"
  install -d "${pkgdir}/usr/share/${pkgname%-git}"

  find . -type f -not -path './.git/*' -exec install {} "${pkgdir}/usr/share/${pkgname%-git}" \;
}