aur/leech/PKGBUILD

42 lines
1.0 KiB
Bash
Raw Normal View History

2024-04-27 12:43:50 +02:00
# Maintainer: Louis Dalibard <ontake@ontake.dev>
2024-08-25 12:58:46 +02:00
_pkgbase="ontake-leech"
2024-04-27 12:43:50 +02:00
pkgname="$_pkgbase-git"
2024-04-28 12:27:29 +02:00
pkgver=r11.gd38556b
2024-04-27 12:43:50 +02:00
pkgrel=1
2024-08-25 12:58:46 +02:00
pkgdesc="A simple HTTP(S) file hosting server with a simple UI."
2024-04-27 12:43:50 +02:00
arch=("x86_64" "armv7h" "aarch64")
url="https://git.ontake.dev/go/leech"
license=('GPL3')
groups=()
depends=()
makedepends=('go>=1.18')
optdepends=()
provides=("$_pkgbase")
conflicts=("$_pkgbase")
replaces=()
backup=()
options=()
install=
changelog=
source=("git+https://git.ontake.dev/go/leech")
noextract=()
md5sums=("SKIP") #autofill using updpkgsums
pkgver() {
2024-08-25 12:58:46 +02:00
cd ${srcdir}/leech
2024-04-27 12:43:50 +02:00
echo "r$(git rev-list --count HEAD).g$(git rev-parse --short HEAD)"
}
build() {
2024-08-25 12:58:46 +02:00
cd "${srcdir}/leech"
2024-04-27 12:43:50 +02:00
go mod tidy
go build
}
package() {
2024-08-25 12:58:46 +02:00
install -Dm755 "${srcdir}/leech/leech" "${pkgdir}"/usr/bin/leech
install -Dm644 "${srcdir}/leech/pkg/config.json" "${pkgdir}"/etc/leech/config.json.example
install -Dm644 "${srcdir}/leech/pkg/leech.service" "${pkgdir}"/usr/lib/systemd/system/leech.service
install -Dm644 "${srcdir}/leech/pkg/sysusers.conf" "${pkgdir}"/usr/lib/sysusers.d/leech.conf
2024-04-27 12:43:50 +02:00
}