blob: 4708ee476251b61a0c54885a8164e8281cc4dd5f (
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
|
# Contributor: Chih-Hsuan Yen <yan12125@archlinux.org>
pkgname=python-evalidate
# https://github.com/yaroslaff/evalidate/releases
pkgver=2.1.3
pkgrel=1
pkgdesc='Safe and fast evaluation of untrusted user-supplied python expressions'
arch=(any)
url='https://github.com/yaroslaff/evalidate'
# https://github.com/yaroslaff/evalidate/blob/v2.0.2/setup.py#L19
license=(MIT)
depends=(python python-faker)
makedepends=(git python-build python-installer python-hatchling python-wheel)
checkdepends=(python-pytest)
source=("git+$url#tag=v$pkgver")
sha256sums=('e427c17b5023058e6b4349bd451ae9d2fa2b53dbd3681f6d026e90b79269959a')
build() {
cd evalidate
python -m build --wheel --no-isolation
}
check() {
cd evalidate
PYTHONPATH="$PWD" pytest tests
}
package() {
cd evalidate
python -m installer --destdir="$pkgdir" dist/*.whl
install -Dm644 LICENSE -t "$pkgdir"/usr/share/licenses/$pkgname
}
|