aboutsummaryrefslogtreecommitdiffstats
path: root/community/croc/APKBUILD
diff options
context:
space:
mode:
Diffstat (limited to 'community/croc/APKBUILD')
-rw-r--r--community/croc/APKBUILD26
1 files changed, 17 insertions, 9 deletions
diff --git a/community/croc/APKBUILD b/community/croc/APKBUILD
index cc2dc7c6e06..49873ca975f 100644
--- a/community/croc/APKBUILD
+++ b/community/croc/APKBUILD
@@ -1,24 +1,27 @@
# Contributor: André Klitzing <aklitzing@@gmail.com>
# Maintainer: André Klitzing <aklitzing@gmail.com>
pkgname=croc
-pkgver=9.3.0
-pkgrel=1
+pkgver=9.6.15
+pkgrel=0
pkgdesc="Easily and securely send things from one computer to another"
url="https://github.com/schollz/croc"
license="MIT"
arch="all"
makedepends="go"
-source="https://github.com/schollz/croc/releases/download/v$pkgver/croc_${pkgver}_src.tar.gz"
+subpackages="$pkgname-bash-completion $pkgname-zsh-completion"
+source="https://github.com/schollz/croc/archive/refs/tags/v$pkgver/croc-$pkgver.tar.gz"
+options="net" # fetch dependencies
# secfixes:
# 9.1.0-r0:
# - CVE-2021-31603
+export GOCACHE="${GOCACHE:-"$srcdir/go-cache"}"
+export GOTMPDIR="${GOTMPDIR:-"$srcdir"}"
+export GOMODCACHE="${GOMODCACHE:-"$srcdir/go"}"
+
build() {
- export CGO_LDFLAGS="$LDFLAGS"
- export GOFLAGS="$GOFLAGS -trimpath -mod=vendor"
- go mod vendor
- go build
+ go build -v -ldflags "-X github.com/schollz/croc/v${pkgver%%.*}/src/cli.Version=v$pkgver"
}
check() {
@@ -26,9 +29,14 @@ check() {
}
package() {
- install -Dm755 -t "$pkgdir"/usr/bin croc
+ install -Dm755 $pkgname -t "$pkgdir"/usr/bin/
+
+ install -Dm644 src/install/bash_autocomplete \
+ "$pkgdir"/usr/share/bash-completion/completions/croc
+ install -Dm644 src/install/zsh_autocomplete \
+ "$pkgdir"/usr/share/zsh/site-functions/_croc
}
sha512sums="
-732a1f1252e2958ea7c9e8273c6c2930da01a4ea71a2ac1056711371235caf6b8200ffafcb73086903ee80fe83948d452e783f49a1c25fdee1089830c148337f croc_9.3.0_src.tar.gz
+8ae76dc5029e7adc809b0083e147c57c7249e9fbb07f263a0b10d21539ebfc69c5d9d8e60811cca06bbb313ec9a3a143baaef73f77ca599dc102626dc9fccf29 croc-9.6.15.tar.gz
"