mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2026-04-19 12:42:30 +02:00
48 lines
1.3 KiB
Plaintext
48 lines
1.3 KiB
Plaintext
# Contributor: Michał Polański <michal@polanski.me>
|
|
# Maintainer: Michał Polański <michal@polanski.me>
|
|
pkgname=dasel
|
|
pkgver=2.7.0
|
|
pkgrel=2
|
|
pkgdesc="Query and modify data structures using selector strings"
|
|
url="https://daseldocs.tomwright.me/"
|
|
license="MIT"
|
|
arch="all"
|
|
makedepends="go"
|
|
subpackages="
|
|
$pkgname-bash-completion
|
|
$pkgname-fish-completion
|
|
$pkgname-zsh-completion
|
|
"
|
|
source="https://github.com/TomWright/dasel/archive/v$pkgver/dasel-$pkgver.tar.gz"
|
|
options="net"
|
|
|
|
export GOCACHE="${GOCACHE:-"$srcdir/go-cache"}"
|
|
export GOTMPDIR="${GOTMPDIR:-"$srcdir"}"
|
|
export GOMODCACHE="${GOMODCACHE:-"$srcdir/go"}"
|
|
|
|
build() {
|
|
go build -ldflags "
|
|
-X github.com/tomwright/dasel/v2/internal.Version=$pkgver
|
|
" ./cmd/dasel
|
|
|
|
./dasel completion bash >$pkgname.bash
|
|
./dasel completion fish >$pkgname.fish
|
|
./dasel completion zsh >$pkgname.zsh
|
|
}
|
|
|
|
check() {
|
|
go test ./...
|
|
}
|
|
|
|
package() {
|
|
install -Dm755 dasel -t "$pkgdir"/usr/bin/
|
|
|
|
install -Dm644 $pkgname.bash "$pkgdir"/usr/share/bash-completion/completions/$pkgname
|
|
install -Dm644 $pkgname.fish "$pkgdir"/usr/share/fish/vendor_completions.d/$pkgname.fish
|
|
install -Dm644 $pkgname.zsh "$pkgdir"/usr/share/zsh/site-functions/_$pkgname
|
|
}
|
|
|
|
sha512sums="
|
|
37753bc124511bc2105186ad62090bda25e8574b5c1ec2cc2583f91e9f8ab41de261f870600ea1a501f41c5ad3b13999c64ca995eee50ee120359f819f6f334a dasel-2.7.0.tar.gz
|
|
"
|