summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: c823ca7fae9346a6391aa178999cb0893e3b3329 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
# Maintainer: Ben Cooper <contactme at bengcooper dot co dot uk>

pkgname=onedev
pkgver=11.6.4
pkgrel=1
_buildid=5774
pkgdesc="A self-hosted Git server with CI/CD and Kanban"
arch=('x86_64')
depends=('java-runtime-headless=17' 'git>2.11.1' 'fontconfig' 'ttf-dejavu')
url="https://code.onedev.io/onedev/server"
license=('custom:OneDev License' 'MIT')
source=("https://code.onedev.io/~downloads/projects/160/builds/$_buildid/artifacts/onedev-$pkgver.tar.gz"
        "sysusers.conf"
        "onedev.service"
        "onedev-upgrade.sh")
sha256sums=('9daa316e11836f312a4b35fe65830214299e84e156b481dec8b090fb21e74ca2'
            'ed8573826c9c89d7a35e3f8b52d4de69c9377fc713b5227bf30f12a45f0c2c82'
            '56c7dea1e61cf81d6dddc34fa098fa5a7ed892b1d3e506cf003b0c2c71bb5866'
            '779eef381def984fed476f253e0cc0e140e379196f8ec2f1656942e1025951f1')
install=onedev.install

package() {
  # Install PKGBUILD files
  install -D -m 0644 sysusers.conf "$pkgdir/usr/lib/sysusers.d/onedev.conf"
  install -D -m 0644 onedev.service "$pkgdir/usr/lib/systemd/system/onedev.service"
  install -D -m 0755 onedev-upgrade.sh "$pkgdir/usr/bin/onedev-upgrade"

  # Install package contents
  cd $pkgname-$pkgver
  install -d "$pkgdir/opt/onedev-base"
  install -o 663 -g 663 -d "$pkgdir/opt/onedev"
  cp -r * "$pkgdir/opt/onedev-base"
  install -D -m 0644 "license.txt" "$pkgdir/usr/share/licenses/onedev/LICENSE"
}