2021-08-26 01:51:58 +00:00
|
|
|
# Maintainer: George Rawlinson <grawlinson@archlinux.org>
|
|
|
|
|
|
|
|
pkgname=python-cron-descriptor
|
|
|
|
_pkgname="${pkgname#python-}"
|
2022-06-29 17:51:41 +00:00
|
|
|
pkgver=1.2.27
|
|
|
|
pkgrel=1
|
|
|
|
pkgdesc='A Python library that converts cron expressions into human readable strings'
|
2021-08-26 01:51:58 +00:00
|
|
|
arch=('any')
|
2022-06-29 17:51:41 +00:00
|
|
|
url='https://github.com/Salamek/cron-descriptor'
|
2021-08-26 01:51:58 +00:00
|
|
|
license=('MIT')
|
|
|
|
depends=('python')
|
2022-06-29 17:51:41 +00:00
|
|
|
makedepends=('git' 'python-setuptools')
|
|
|
|
_commit='9435edb5373f08eb6eb206e4e17ccbac495d6135'
|
|
|
|
source=("$pkgname::git+$url#commit=$_commit")
|
|
|
|
b2sums=('SKIP')
|
|
|
|
|
|
|
|
pkgver() {
|
|
|
|
cd "$pkgname"
|
|
|
|
|
|
|
|
git describe --tags | sed 's/^v//'
|
|
|
|
}
|
2021-08-26 01:51:58 +00:00
|
|
|
|
|
|
|
build() {
|
2022-06-29 17:51:41 +00:00
|
|
|
cd "$pkgname"
|
|
|
|
|
2021-08-26 01:51:58 +00:00
|
|
|
python setup.py build
|
|
|
|
}
|
|
|
|
|
|
|
|
check() {
|
2022-06-29 17:51:41 +00:00
|
|
|
cd "$pkgname"
|
|
|
|
|
2021-08-26 01:51:58 +00:00
|
|
|
python -m unittest
|
|
|
|
}
|
|
|
|
|
|
|
|
package() {
|
2022-06-29 17:51:41 +00:00
|
|
|
cd "$pkgname"
|
|
|
|
|
2021-08-26 01:51:58 +00:00
|
|
|
python setup.py install --root="$pkgdir" --optimize=1
|
|
|
|
|
|
|
|
# documentation
|
|
|
|
install -vDm644 -t "$pkgdir/usr/share/doc/$pkgname" README.md
|
|
|
|
cp -vr examples "$pkgdir/usr/share/doc/$pkgname"
|
|
|
|
|
|
|
|
# license
|
|
|
|
install -vDm644 -t "$pkgdir/usr/share/licenses/$pkgname" LICENSE
|
|
|
|
}
|