| 1 | # Maintainer: Patrycja Rosa <[email protected]> |
| 2 | pkgname=diceware |
| 3 | pkgver=1.0.1 |
| 4 | pkgrel=1 |
| 5 | pkgdesc="Passphrases you will remember" |
| 6 | url="https://github.com/ulif/diceware" |
| 7 | arch="noarch" |
| 8 | license="GPL-3.0-or-later" |
| 9 | makedepends="py3-gpep517 py3-setuptools py3-wheel" |
| 10 | checkdepends="py3-pytest" |
| 11 | subpackages="$pkgname-pyc" |
| 12 | source="https://github.com/ulif/diceware/archive/v$pkgver/diceware-$pkgver.tar.gz" |
| 13 | |
| 14 | build() { |
| 15 | gpep517 build-wheel \ |
| 16 | --wheel-dir .dist \ |
| 17 | --output-fd 3 3>&1 >&2 |
| 18 | } |
| 19 | |
| 20 | check() { |
| 21 | python3 -m venv --clear --without-pip --system-site-packages .testenv |
| 22 | .testenv/bin/python3 -m installer .dist/*.whl |
| 23 | # test_can_run_run: broken logic for trying to run itself from the tests |
| 24 | .testenv/bin/python3 -m pytest \ |
| 25 | --deselect tests/test_main.py::test_can_run_run |
| 26 | } |
| 27 | |
| 28 | package() { |
| 29 | python3 -m installer -d "$pkgdir" \ |
| 30 | .dist/*.whl |
| 31 | } |
| 32 | |
| 33 | sha512sums=" |
| 34 | c29eebf05eba87b9f9b7845aa392eb50e74b7f9d7361e93ae19aa6343da39f030b00caf2d5e29499d8c9b714e5b7caccdefe5eafb6f78e780a5ca61c737a6513 diceware-1.0.1.tar.gz |
| 35 | " |