Pkgfile 896 B

12345678910111213141516171819202122232425262728
  1. # Description: GitHub's official command line tool
  2. # URL: https://cli.github.com/
  3. # Maintainer: Daniel Azevedo, daniazevedo77 at posteo dot net
  4. # Depends on: go
  5. name=gh
  6. version=2.65.0
  7. release=1
  8. source=(https://github.com/cli/cli/archive/v$version/$name-$version.tar.gz)
  9. build() {
  10. cd cli-$version
  11. export CGO_CPPFLAGS="${CPPFLAGS}"
  12. export CGO_CFLAGS="${CFLAGS}"
  13. export CGO_CXXFLAGS="${CXXFLAGS}"
  14. export CGO_LDFLAGS="${LDFLAGS}"
  15. export GOFLAGS="-buildmode=pie -trimpath -mod=readonly -modcacherw -ldflags=-linkmode=external"
  16. make GH_VERSION="v$version" bin/gh manpages
  17. bin/gh completion -s bash | install -Dm644 /dev/stdin share/bash-completion/completions/gh
  18. bin/gh completion -s zsh | install -Dm644 /dev/stdin share/zsh/site-functions/_gh
  19. bin/gh completion -s fish | install -Dm644 /dev/stdin share/fish/vendor_completions.d/gh.fish
  20. make DESTDIR="${PKG}" prefix="/" install
  21. }