summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorAndriy Cherniy2023-12-22 20:38:25 +0000
committerAndriy Cherniy2023-12-22 20:38:25 +0000
commita8e7cca3a207f6ac013d89abb5685ac42471bf46 (patch)
tree65823aa9df7e78e6c035a740c2a344e5a1b699c6 /PKGBUILD
downloadaur-dwm-polybar-git.tar.gz
initial commit
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD32
1 files changed, 32 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..a4bfb92da235
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,32 @@
+# Maintainer: Andriy Cherniy <qugalet@m0e.space>
+
+pkgname=dwm-polybar-git
+pkgdesc='Polybar script in Go without recompiling entire polybar '
+pkgver=0.r6
+pkgrel=1
+url='https://github.com/Andrmist/dwm-polybar'
+license=(MIT)
+arch=(x86_64 i686)
+makedepends=(go-pie git)
+source=("${pkgname}::git+${url}")
+sha512sums=(SKIP)
+
+pkgver () {
+ cd "${pkgname}"
+ echo "0.r$(git rev-list --count HEAD)"
+}
+
+build () {
+ cd "${pkgname}"
+ local curdir=$(pwd)
+ go build -v \
+ -gcflags "all=-trimpath=${curdir}" \
+ -asmflags "all=-trimpath=${curdir}" \
+ -ldflags "-extldflags '${LDFLAGS}'" \
+ .
+}
+
+package () {
+ cd "${pkgname}"
+ install -Dm755 dwm-polybar "${pkgdir}/usr/bin/dwm-polybar"
+}