# This file is part of BlackArch Linux ( https://www.blackarch.org/ ). # See COPYING for license details. pkgname=wuzz pkgver=v0.5.0.r16.g791aeb9 pkgrel=2 epoch=1 groups=('blackarch' 'blackarch-webapp' 'blackarch-misc') pkgdesc='Interactive cli tool for HTTP inspection.' arch=('x86_64' 'aarch64') url='https://github.com/asciimoo/wuzz' license=('AGPL3') makedepends=('git' 'go') source=("git+https://github.com/asciimoo/$pkgname.git") sha512sums=('SKIP') pkgver() { cd $pkgname ( set -o pipefail git describe --long --tags --abbrev=7 2>/dev/null | sed 's/\([^-]*-g\)/r\1/;s/-/./g' || printf "%s.%s" "$(git rev-list --count HEAD)" \ "$(git rev-parse --short=7 HEAD)" ) } build() { cd $pkgname GOPATH="$srcdir" go mod download GOPATH="$srcdir" go build \ -trimpath \ -buildmode=pie \ -mod=readonly \ -modcacherw \ -ldflags "-s -w" \ -o $pkgname . } package() { cd "$pkgname" install -Dm 755 $pkgname "$pkgdir/usr/bin/$pkgname" install -Dm 644 -t "$pkgdir/usr/share/doc/$pkgname/" README.md install -Dm 644 LICENSE -t "$pkgdir/usr/share/licenses/$pkgname" cp -a docs/* "$pkgdir/usr/share/doc/$pkgname/" }