summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 76bdc7b6f22d18a4247ca4a5416c69faec3464ec (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
# $Id$
# Maintainer: Kemad Zhong <kemadz@gmail.com>

pkgname=jsonfmt
pkgver=0.4.0
pkgrel=1
pkgdesc="Like gofmt, but for JSON files."
url="https://github.com/caarlos0/jsonfmt"
license=("LGPL")
arch=('x86_64')
depends=('git')
makedepends=('go')
source=("git+$url#tag=v$pkgver")
sha512sums=('SKIP')

build() {
  cd "$srcdir/$pkgname"
  CGO_ENABLED=0 go build --ldflags "-X main.version=$pkgver"
}

package() {
  install -Dm 755 "$srcdir/$pkgname/$pkgname" "$pkgdir/usr/bin/$pkgname"
}