mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-04-17 02:16:39 +02:00
50 lines
1.4 KiB
Text
50 lines
1.4 KiB
Text
# Contributor: Alexander Sharov <kvendingoldo@gmail.com>
|
|
# Maintainer: Alexander Sharov <kvendingoldo@gmail.com>
|
|
pkgname=tenv
|
|
pkgver=4.2.4
|
|
pkgrel=2
|
|
pkgdesc="OpenTofu, Terraform, Terragrunt, and Atmos version manager"
|
|
license="Apache-2.0"
|
|
arch="all"
|
|
url="https://github.com/tofuutils/tenv"
|
|
source="tenv-$pkgver.tar.gz::https://github.com/tofuutils/tenv/archive/v$pkgver.tar.gz"
|
|
options="net"
|
|
depends="cosign !terraform !tofu !terragrunt !atmos"
|
|
makedepends="go cosign"
|
|
|
|
subpackages="
|
|
$pkgname-bash-completion
|
|
$pkgname-fish-completion
|
|
$pkgname-zsh-completion
|
|
"
|
|
|
|
export GOCACHE="${GOCACHE:-"$srcdir/go-cache"}"
|
|
export GOTMPDIR="${GOTMPDIR:-"$srcdir"}"
|
|
export GOMODCACHE="${GOMODCACHE:-"$srcdir/go"}"
|
|
|
|
build() {
|
|
local i
|
|
mkdir build
|
|
for i in tenv terraform terragrunt tf tofu atmos; do
|
|
go build -ldflags "-s -w -X main.version=v$pkgver" -o build/$i ./cmd/$i
|
|
done
|
|
|
|
for i in bash fish zsh; do
|
|
./build/tenv completion $i > ./tenv.$i
|
|
done
|
|
}
|
|
|
|
check() {
|
|
make test
|
|
}
|
|
|
|
package() {
|
|
install -Dm755 -t "$pkgdir"/usr/bin build/*
|
|
|
|
install -Dm644 ./tenv.bash $pkgdir/usr/share/bash-completion/completions/tenv
|
|
install -Dm644 ./tenv.fish $pkgdir/usr/share/fish/vendor_completions.d/tenv.fish
|
|
install -Dm644 ./tenv.zsh $pkgdir/usr/share/zsh/site-functions/tenv
|
|
}
|
|
|
|
sha512sums="
|
|
8923b5dd36a34f124c82b252ec49231cabe2e0221082c022fe12af90abb47d6faa007580881f0778b0f3aa21591e21d6405aede0c7c9c95f7dd0351b49766508 tenv-4.2.4.tar.gz"
|