summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorSam Tay2020-02-18 15:39:40 -0800
committerSam Tay2020-02-18 15:39:40 -0800
commitd19996c0a5c6c2ccc71579ac1387f5c8cac3935a (patch)
tree9ffc040b2d673953d12ec77bb0d0419fae6b7920
downloadaur-d19996c0a5c6c2ccc71579ac1387f5c8cac3935a.tar.gz
Initial (pre-)release
-rw-r--r--.SRCINFO14
-rw-r--r--PKGBUILD32
2 files changed, 46 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..2f9698adfae2
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,14 @@
+pkgbase = so-git
+ pkgdesc = Terminal interface for StackExchange
+ pkgver = r114.58be873
+ pkgrel = 1
+ url = https://github.com/samtay/so
+ arch = i686
+ arch = x86_64
+ license = custom
+ makedepends = stack
+ source = so::git+https://github.com/samtay/so
+ md5sums = SKIP
+
+pkgname = so-git
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..d2dd6d401877
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,32 @@
+# Maintainer: Sam Tay <samdotchongdottayatgmaildotcom>
+
+pkgname=so-git
+_pkgname=so
+pkgver=r114.58be873
+pkgrel=1
+pkgdesc="Terminal interface for StackExchange"
+arch=('i686' 'x86_64')
+url="https://github.com/samtay/so"
+license=('custom')
+makedepends=('stack')
+source=("${_pkgname}"::'git+https://github.com/samtay/so')
+md5sums=('SKIP')
+
+pkgver() {
+ cd "$srcdir/${_pkgname}"
+ ( set -o pipefail
+ git describe --long 2>/dev/null | sed 's/\([^-]*-g\)/r\1/;s/-/./g' ||
+ printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
+ )
+}
+
+build() {
+ cd "$srcdir/${_pkgname}"
+ stack build --ghc-build=tinfo6
+}
+
+package() {
+ cd "$srcdir/${_pkgname}"
+ stack install --ghc-build=tinfo6 --local-bin-path="${pkgdir}/usr/bin"
+ install -Dm644 -t "${pkgdir}/usr/share/licenses/${pkgname}" LICENSE
+}