summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorTony Lambiris2018-11-26 13:05:57 -0500
committerTony Lambiris2018-11-26 13:05:57 -0500
commitb654179b7af6231440cdd0316fffb48d90c62f08 (patch)
treed97f58eb9b521e8938126cd02740c4a78ecd4130 /PKGBUILD
downloadaur-komanda-cli-git.tar.gz
Initial commit
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD39
1 files changed, 39 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 00000000000..62784d5a11d
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,39 @@
+# Maintainer: Tony Lambiris <tony@criticalstack.com>
+
+pkgname=komanda-cli-git
+pkgver=v0.9.4.r15.g61e52d1
+pkgrel=1
+pkgdesc='The Komanda Command-line IRC Client'
+arch=(x86_64)
+url='https://github.com/mephux/komanda-cli'
+license=(BSD)
+makedepends=(go dep)
+source=("${pkgname}::git+https://github.com/mephux/komanda-cli.git")
+sha256sums=('SKIP')
+
+pkgver() {
+ cd "${srcdir}/${pkgname}"
+
+ git describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g'
+}
+
+prepare() {
+ cd "${srcdir}/${pkgname}"
+
+ install -m755 -d "${srcdir}/go/src/github.com/mephux/"
+ cp -a "${srcdir}/${pkgname}" "${srcdir}/go/src/github.com/mephux/komanda-cli"
+}
+
+build() {
+ cd "${srcdir}/go/src/github.com/mephux/komanda-cli"
+
+ export GOROOT="/usr/lib/go" GOPATH="${srcdir}/go"
+ make
+}
+
+package() {
+ cd "${srcdir}/go/src/github.com/mephux/komanda-cli"
+
+ install -Dm755 bin/komanda "${pkgdir}"/usr/bin/komanda
+ install -Dm644 LICENSE "${pkgdir}"/usr/share/licenses/komanda-cli/LICENSE
+}