mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-07-14 03:39:53 +03:00
51 lines
1.3 KiB
Text
51 lines
1.3 KiB
Text
# Contributor: Antoine Martin (ayakael) <dev@ayakael.net>
|
|
# Maintainer: Antoine Martin (ayakael) <dev@ayakael.net>
|
|
pkgname=py3-django-otp
|
|
_pyname=django_otp
|
|
pkgver=1.6.0
|
|
pkgrel=0
|
|
arch="noarch"
|
|
pkgdesc="A pluggable framework for adding two-factor authentication to Django using one-time passwords."
|
|
url="https://pypi.python.org/project/django-otp"
|
|
license="BSD-2-Clause"
|
|
# also supports py3-segno
|
|
depends="
|
|
py3-django
|
|
py3-qrcode
|
|
"
|
|
makedepends="
|
|
py3-gpep517
|
|
py3-setuptools
|
|
py3-wheel
|
|
py3-hatchling
|
|
"
|
|
checkdepends="
|
|
py3-freezegun
|
|
"
|
|
source="$pkgname-$pkgver.tar.gz::https://pypi.io/packages/source/d/django-otp/django_otp-$pkgver.tar.gz"
|
|
builddir="$srcdir"/$_pyname-$pkgver
|
|
subpackages="$pkgname-pyc"
|
|
|
|
build() {
|
|
gpep517 build-wheel \
|
|
--wheel-dir .dist \
|
|
--output-fd 3 3>&1 >&2
|
|
}
|
|
|
|
check() {
|
|
python3 -m venv --clear --without-pip --system-site-packages .testenv
|
|
.testenv/bin/python3 -m installer .dist/*.whl
|
|
PYTHONPATH="test" \
|
|
DJANGO_SETTINGS_MODULE="test_project.settings" \
|
|
.testenv/bin/python3 -s -m django test -v 2 django_otp
|
|
}
|
|
|
|
package() {
|
|
python3 -m installer -d "$pkgdir" \
|
|
.dist/*.whl
|
|
install -Dm644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
|
|
}
|
|
|
|
sha512sums="
|
|
6800fc61fcf674933a8f0bb928fa97ac794075bc937022866c97d25b2d7f1a02f7402383d487c7a4d7e1bb48abc2ad6fa8c4d808c15222ba8cff35c909b2b22d py3-django-otp-1.6.0.tar.gz
|
|
"
|