2021-08-26 01:36:47 +00:00
|
|
|
# Maintainer: George Rawlinson <grawlinson@archlinux.org>
|
|
|
|
# Contributor: Mark Wagie <mark dot wagie at tutanota dot com>
|
|
|
|
# Contributor: Thomas Andrejak <thomas.andrejak@gmail.com>
|
|
|
|
|
|
|
|
pkgname=python-croniter
|
2022-11-23 07:47:27 +00:00
|
|
|
pkgver=1.3.8
|
2022-01-15 07:39:57 +00:00
|
|
|
pkgrel=1
|
2022-06-18 04:02:35 +00:00
|
|
|
pkgdesc='Provides iteration for the datetime object with a cron like format'
|
2021-08-26 01:36:47 +00:00
|
|
|
arch=('any')
|
2022-06-18 04:02:35 +00:00
|
|
|
url='https://github.com/kiorky/croniter'
|
2021-08-26 01:36:47 +00:00
|
|
|
license=('MIT')
|
2022-02-23 08:04:42 +00:00
|
|
|
depends=('python' 'python-dateutil' 'python-natsort')
|
2022-11-23 07:47:27 +00:00
|
|
|
makedepends=(
|
|
|
|
'git'
|
|
|
|
'python-build'
|
|
|
|
'python-installer'
|
|
|
|
'python-wheel'
|
|
|
|
'python-setuptools'
|
|
|
|
)
|
2021-08-26 01:36:47 +00:00
|
|
|
checkdepends=('python-pytest' 'python-pytz')
|
2022-11-23 07:47:27 +00:00
|
|
|
_commit='ddbee2c6cbb2bd6ccbf73a9ef1e2e223fa0d6c73'
|
2022-02-23 08:04:42 +00:00
|
|
|
source=("$pkgname::git+$url.git#commit=$_commit")
|
|
|
|
b2sums=('SKIP')
|
|
|
|
|
|
|
|
pkgver() {
|
|
|
|
cd "$pkgname"
|
|
|
|
|
|
|
|
git describe --tags | sed 's/^v//'
|
|
|
|
}
|
2021-08-26 01:36:47 +00:00
|
|
|
|
|
|
|
build() {
|
2022-02-23 08:04:42 +00:00
|
|
|
cd "$pkgname"
|
|
|
|
|
2022-11-23 07:47:27 +00:00
|
|
|
python -m build --wheel --no-isolation
|
2021-08-26 01:36:47 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
check() {
|
2022-02-23 08:04:42 +00:00
|
|
|
cd "$pkgname"
|
|
|
|
|
2022-11-23 07:47:27 +00:00
|
|
|
pytest -v
|
2021-08-26 01:36:47 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
package() {
|
2022-02-23 08:04:42 +00:00
|
|
|
cd "$pkgname"
|
|
|
|
|
2022-11-23 07:47:27 +00:00
|
|
|
python -m installer --destdir="$pkgdir" dist/*.whl
|
2021-08-26 01:36:47 +00:00
|
|
|
|
|
|
|
# license
|
2022-11-23 07:47:27 +00:00
|
|
|
install -vDm644 -t "$pkgdir/usr/share/licenses/$pkgname" LICENSE
|
2021-08-26 01:36:47 +00:00
|
|
|
|
|
|
|
# documentation
|
2022-11-23 07:47:27 +00:00
|
|
|
install -vDm644 -t "$pkgdir/usr/share/doc/$pkgname" {README,CHANGELOG}.rst
|
2021-08-26 01:36:47 +00:00
|
|
|
}
|