summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 74840af5b941ed7ad43a674aae0719cd8f6cfa8f (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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
# This file was generated by GoReleaser. DO NOT EDIT.
# Maintainer: Alexander Sharov <kvendingoldo@gmail.com>
# Maintainer: chaseme <aur@chase.ninja>
# Contributor: Alexander Sharov <kvendingoldo@gmail.com>
# Contributor: chaseme <aur@chase.ninja>

pkgname='tenv-bin'
pkgver=2.7.2
pkgrel=1
pkgdesc='OpenTofu, Terraform, Terragrunt, and Atmos version manager, written in Go.'
url='https://tofuutils.github.io/tenv/'
arch=('aarch64' 'i686' 'x86_64')
license=('Apache-2.0')
provides=('atmos' 'tenv' 'terraform' 'terragrunt' 'tf' 'tofu')
conflicts=('atmos' 'atmos-bin' 'opentofu' 'opentofu-bin' 'opentofu-bin-stable' 'opentofu-git' 'terraform' 'terragrunt' 'tfenv' 'tgenv' 'tofuenv')
optdepends=('cosign: package validation for OpenTofu')

source_aarch64=("${pkgname}_${pkgver}_aarch64.tar.gz::https://github.com/tofuutils/tenv/releases/download/v2.7.2/tenv_v2.7.2_Linux_arm64.tar.gz")
sha256sums_aarch64=('8536f75033b48ffc21244cf276232455b40d2f3cc63510d69384a7605545112c')

source_i686=("${pkgname}_${pkgver}_i686.tar.gz::https://github.com/tofuutils/tenv/releases/download/v2.7.2/tenv_v2.7.2_Linux_i386.tar.gz")
sha256sums_i686=('0fd5c371eeea9793632f6e1b397584cf224fecbb353a5fa3ed23f7019cf55669')

source_x86_64=("${pkgname}_${pkgver}_x86_64.tar.gz::https://github.com/tofuutils/tenv/releases/download/v2.7.2/tenv_v2.7.2_Linux_x86_64.tar.gz")
sha256sums_x86_64=('c80e319b0e6f6db755ab41d0a3ab5e8366bdb94f8b32db3d92a698d6b6b612e2')

package() {
  # bin
  install -Dm 0755 "atmos" "${pkgdir}/usr/bin/atmos"
  install -Dm 0755 "tenv" "${pkgdir}/usr/bin/tenv"
  install -Dm 0755 "terraform" "${pkgdir}/usr/bin/terraform"
  install -Dm 0755 "terragrunt" "${pkgdir}/usr/bin/terragrunt"
  install -Dm 0755 "tf" "${pkgdir}/usr/bin/tf"
  install -Dm 0755 "tofu" "${pkgdir}/usr/bin/tofu"

  # license
  install -Dm 0644 "LICENSE" "${pkgdir}/usr/share/licenses/tenv/LICENSE"
  install -Dm 0644 "LICENSE" "${pkgdir}/usr/share/doc/tenv/LICENSE"

  # readme
  install -Dm 0644 "README.md" "${pkgdir}/usr/share/doc/tenv/README.md"

  # completions
  mkdir -p "${pkgdir}/usr/share/bash-completion/completions/"
  mkdir -p "${pkgdir}/usr/share/zsh/site-functions/"
  mkdir -p "${pkgdir}/usr/share/fish/vendor_completions.d/"

  for i in bash fish zsh; do
  ./tenv completion $i > ./tenv.$i
  done

  install -Dm644 "./tenv.bash" "${pkgdir}/usr/share/bash-completion/completions/tenv"
  install -Dm644 "./tenv.zsh" "${pkgdir}/usr/share/zsh/site-functions/tenv"
  install -Dm644 "./tenv.fish" "${pkgdir}/usr/share/fish/vendor_completions.d/tenv.fish"
}