[arch-commits] Commit in python-flake8-docstrings/trunk (PKGBUILD)
Daniel M. Capella
polyzen at gemini.archlinux.org
Tue Sep 6 04:42:12 UTC 2022
Date: Tuesday, September 6, 2022 @ 04:42:11
Author: polyzen
Revision: 1294164
upgpkg: python-flake8-docstrings 1.6.0-3: Use PEP 517
Modified:
python-flake8-docstrings/trunk/PKGBUILD
----------+
PKGBUILD | 23 +++++++++++------------
1 file changed, 11 insertions(+), 12 deletions(-)
Modified: PKGBUILD
===================================================================
--- PKGBUILD 2022-09-06 04:08:37 UTC (rev 1294163)
+++ PKGBUILD 2022-09-06 04:42:11 UTC (rev 1294164)
@@ -4,13 +4,14 @@
_name=flake8-docstrings
pkgname=python-flake8-docstrings
pkgver=1.6.0
-pkgrel=2
+pkgrel=3
pkgdesc='Plugin to Flake8 to include checks provided by pydocstyle'
arch=('any')
url=https://gitlab.com/pycqa/flake8-docstrings
license=('MIT')
depends=('flake8' 'python-pydocstyle')
-makedepends=('python-setuptools')
+makedepends=('python-build' 'python-installer' 'python-setuptools'
+ 'python-wheel')
source=("https://files.pythonhosted.org/packages/source/${_name::1}/$_name/$_name-$pkgver.tar.gz")
sha256sums=('9fe7c6a306064af8e62a055c2f61e9eb1da55f84bb39caef2b84ce53708ac34b')
b2sums=('ee147e27f226675a2a59375b9e7812d111a34bef1bc35843096f8e7ca9cd94ac805ca49a8d83d1f6d7a78dbf6338a0a1270d668b51775a2b91ad7c3172ad41da')
@@ -17,18 +18,16 @@
build() {
cd $_name-$pkgver
- python setup.py build
+ python -m build --wheel --skip-dependency-check --no-isolation
}
-check() {
+package() {
cd $_name-$pkgver
- python -m venv --system-site-packages test-env
- test-env/bin/python setup.py install --optimize=1 --skip-build
- test-env/bin/python -m flake8 flake8_docstrings.py
-}
+ python -m installer --destdir="$pkgdir" dist/*.whl
-package() {
- cd $_name-$pkgver
- python setup.py install --root="$pkgdir" --optimize=1 --skip-build
- install -Dm644 -t "$pkgdir"/usr/share/licenses/$pkgname LICENSE
+ # Symlink license file
+ local site_packages=$(python -c "import site; print(site.getsitepackages()[0])")
+ install -d "$pkgdir"/usr/share/licenses/$pkgname
+ ln -s "$site_packages"/flake8_docstrings-$pkgver.dist-info/LICENSE \
+ "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
}
More information about the arch-commits
mailing list