# Maintainer: Olivier Gayot pkgname=phpdoc-git pkgver=1 pkgrel=1 pkgdesc="Read the documentation of PHP functions in your terminal" arch=('any') url="https://git.sigexec.com/cgit.cgi/phpdoc.git/" license=('BSD') depends=('sed' 'which') makedepends=('git') optdepends=('w3m' 'php-docs') provides=("${pkgname%-git}") conflicts=("${pkgname%-git}") source=("${pkgname}::git+https://git.sigexec.com/cgit.cgi/${pkgname%-git}.git") md5sums=('SKIP') pkgver() { cd "$srcdir/${pkgname}" ## Git, tags available # printf "%s" "$(git describe --long | sed 's/\([^-]*-\)g/r\1/;s/-/./g')" # Git, no tags available printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)" } package() { cd "${srcdir}/${pkgname}" install -D phpdoc.sh "${pkgdir}/usr/bin/phpdoc" }