summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 6ccbe315f2dcbc33dab5a6a5908dac91a0f31ac6 (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
# Maintainer: Sam Whited <sam@samwhited.com>

pkgname=writeas-cli
pkgver=2.0.0
pkgrel=4
pkgdesc="Write.as command line interface"
arch=('x86_64')
url='https://write.as/apps/cli'
license=('GPL3')
depends=('glibc')
makedepends=('go')
source=("${pkgname}-${pkgver}.tar.gz::https://github.com/writeas/writeas-cli/archive/v${pkgver}-wf.tar.gz")
sha256sums=('e70e47e3ed28f26ca2ffb12723ddbdaffdea9a6a8db5a1e8a34272c1ef8511aa')

build() {
	cd ${pkgname}-${pkgver}-wf
	go build \
		-trimpath \
		-ldflags "-extldflags=${LDFLAGS}" \
		-buildmode=pie \
		./cmd/writeas/
	go build \
		-trimpath \
		-ldflags "-extldflags=${LDFLAGS}" \
		-buildmode=pie \
		./cmd/wf/
}

package() {
	install -Dm755 "${srcdir}/${pkgname}-${pkgver}-wf/writeas" "${pkgdir}/usr/bin/writeas"
	install -Dm755 "${srcdir}/${pkgname}-${pkgver}-wf/wf" "${pkgdir}/usr/bin/wf"
}