summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 5c1be0cc2a929b862643fb48717d33614b4f252d (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
35
# Maintainer: Vojtech Horky <github.com/vhotspur>

pkgname=d3s-nagios-plugins-git
_reponame="d3s-nagios-plugins"
pkgver=r9.9865cf3
pkgrel=1
pkgdesc="A collection of various mini-plugins for Nagios."
arch=('any')
license=('Apache')
url="https://github.com/D-iii-S/d3s-nagios-plugins"
# Most AUR helpers unfortunately do not support versioned deps in the AUR ("python-acme=${pkgver}")
depends=('python')
makedepends=('git' 'python-setuptools')
source=("${_reponame}"::"git+https://github.com/D-iii-S/${_reponame}.git")
sha512sums=('SKIP')

pkgver() {
	cd "${srcdir}/${_reponame}"
	( set -o pipefail
	   git describe --long 2>/dev/null | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g' \
	   || printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
	)
}

build() {
    cd "${srcdir}/${_reponame}"

    python setup.py build
}

package() {
    cd "${srcdir}/${_reponame}"
    
    python setup.py install --root="${pkgdir}" --optimize=1 --skip-build
}