blob: fb2baf274dca091101788827133ae403470cb508 (
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
|
# Maintainer: a821 at mail de
# Contributor: Chih-Hsuan Yen <yan12125@archlinux.org>
pkgname=python-scramp
pkgver=1.4.5
_commit=59198327bdff4cb2f9e5563b5312ea11a91231fe
pkgrel=1
pkgdesc="Python implementation of the SCRAM protocol"
arch=(any)
url='https://github.com/tlocke/scramp'
license=('MIT-0')
depends=(python python-asn1crypto)
makedepends=(
git
python-build
python-installer
python-hatchling
python-setuptools
python-versioningit
python-wheel
)
checkdepends=(python-pytest python-pytest-mock python-passlib)
source=("git+$url.git?signed#commit=$_commit")
sha256sums=('e5d52be2224b30b399d7dd7a21250ee4d3371b1b5680362104652eed0e2087c0')
validpgpkeys=(
'D5681B7EC7292511C4CC1450892B00AB699851E8' # Tony Locke <tlocke@tlocke.org.uk>, proven by https://keybase.io/tlocke
)
pkgver() {
cd scramp
git describe --tags
}
build() {
cd scramp
python -m build --wheel --no-isolation
}
check() {
cd scramp
# install to temporary dir
local _pyver=$(python -c 'import sys; print(*sys.version_info[:2], sep=".")')
python -m installer --destdir=temp dist/*.whl
PYTHONPATH=temp/usr/lib/python$_pyver/site-packages pytest
}
package() {
cd scramp
python -m installer --destdir="$pkgdir" dist/*.whl
install -Dm644 LICENSE -t "$pkgdir"/usr/share/licenses/$pkgname
}
|