BlueGit

timfa bluegit

Files

bluegit / packaging / arch / PKGBUILD

PKGBUILD

PKGBUILD 1.5 KiB Download Raw
1# Maintainer: Tim Falken <tim@timfalken.com>
2pkgname=bluegit
3pkgver=0.1.0
4pkgrel=1
5pkgdesc='Self-hosted git-platform voor git.timfalken.com'
6arch=('x86_64')
7url='https://git.timfalken.com'
8license=('MIT')
9depends=('git' 'docker')
10makedepends=('go')
11backup=('etc/bluegit/config.yml')
12options=('!debug')
13
14build() {
15 local root
16 root="$(cd "$startdir/../.." && pwd)"
17 cd "$root"
18 export CGO_ENABLED=0
19 # go.mod vraagt Go 1.26; een oudere Arch-go haalt die toolchain zelf op.
20 export GOTOOLCHAIN=auto
21 export GOFLAGS='-trimpath'
22 go build -ldflags='-s -w' -o "$srcdir/bluegit" ./cmd/bluegit
23}
24
25package() {
26 local root
27 root="$(cd "$startdir/../.." && pwd)"
28 install -Dm755 "$srcdir/bluegit" "$pkgdir/usr/bin/bluegit"
29 install -Dm644 "$root/packaging/bluegit.service" "$pkgdir/usr/lib/systemd/system/bluegit.service"
30 install -Dm644 "$root/packaging/bluegit.yml" "$pkgdir/etc/bluegit/config.yml"
31 install -Dm644 "$root/packaging/storage.conf" "$pkgdir/usr/share/bluegit/storage.conf.example"
32 install -Dm644 "$root/packaging/sysusers.conf" "$pkgdir/usr/lib/sysusers.d/bluegit.conf"
33 install -Dm644 "$root/packaging/tmpfiles.conf" "$pkgdir/usr/lib/tmpfiles.d/bluegit.conf"
34 install -Dm755 "$root/packaging/bluegit-update.sh" "$pkgdir/usr/lib/bluegit/update"
35 install -Dm644 "$root/packaging/bluegit-update.service" "$pkgdir/usr/lib/systemd/system/bluegit-update.service"
36 install -Dm644 "$root/packaging/bluegit-update.rules" "$pkgdir/usr/share/polkit-1/rules.d/49-bluegit-update.rules"
37}