2021-08-26 01:51:58 +00:00
|
|
|
# Maintainer: George Rawlinson <grawlinson@archlinux.org>
|
|
|
|
|
|
|
|
pkgname=python-cron-descriptor
|
|
|
|
_pkgname="${pkgname#python-}"
|
2023-01-25 22:05:20 +00:00
|
|
|
pkgver=1.2.34
|
2022-06-29 17:51:41 +00:00
|
|
|
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-11-23 07:40:07 +00:00
|
|
|
makedepends=(
|
|
|
|
'git'
|
|
|
|
'python-build'
|
|
|
|
'python-installer'
|
|
|
|
'python-wheel'
|
|
|
|
'python-setuptools'
|
|
|
|
)
|
2023-01-25 22:05:20 +00:00
|
|
|
checkdepends=('python-mock')
|
|
|
|
_commit='f1a0c3c5b3ad49e0e9815b3d777af30155cb85b3'
|
2022-06-29 17:51:41 +00:00
|
|
|
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"
|
|
|
|
|
2022-11-23 07:40:07 +00:00
|
|
|
python -m build --wheel --no-isolation
|
2021-08-26 01:51:58 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
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"
|
|
|
|
|
2022-11-23 07:40:07 +00:00
|
|
|
python -m installer --destdir="$pkgdir" dist/*.whl
|
2021-08-26 01:51:58 +00:00
|
|
|
|
|
|
|
# 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
|
|
|
|
}
|