blob: 4f701bfbe6c33a9843011f1c4946f69eee382983 (
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
33
34
35
36
|
# Maintainer: Hoang Nguyen <folliekazetani@protonmail.com>
pkgname=kubectl-krew
pkgver=0.4.3
pkgrel=10
pkgdesc="Find and install kubectl plugins"
url="https://krew.sigs.k8s.io/"
arch="x86_64 aarch64 armv7 x86" # kubectl
license="Apache-2.0"
depends="kubectl"
makedepends="go"
source="$pkgname-$pkgver.tar.gz::https://github.com/kubernetes-sigs/krew/archive/refs/tags/v$pkgver.tar.gz"
builddir="$srcdir/krew-$pkgver"
export GOCACHE="${GOCACHE:-"$srcdir/go-cache"}"
export GOTMPDIR="${GOTMPDIR:-"$srcdir"}"
export GOMODCACHE="${GOMODCACHE:-"$srcdir/go"}"
build() {
GOLDFLAGS="
-X sigs.k8s.io/krew/internal/version.gitCommit=AlpineLinux
-X sigs.k8s.io/krew/internal/version.gitTag=v$pkgver
"
go build -tags netgo -ldflags "$GOLDFLAGS" -o bin/$pkgname ./cmd/krew/main.go
}
check() {
KREW_BINARY="$builddir/bin/$pkgname" go test ./...
}
package() {
install -Dm755 bin/$pkgname "$pkgdir"/usr/bin/$pkgname
}
sha512sums="
a9846b98e9ddcb6912df8821fc9b99ed007806a6e940032c08146b79a15896e30f6ed49780ba84f3c388cd98dba866efeec968ef4ce8eda4faa0c1426fd9b145 kubectl-krew-0.4.3.tar.gz
"
|