summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorLuis Martinez2022-03-31 16:17:17 -0500
committerLuis Martinez2022-03-31 16:17:17 -0500
commit3483a482231dbdcdc70005a57bf6a8889c0c2be1 (patch)
tree864105dc367ba440139f09bc1e19f86422a8209d
parent6e3b30b0034c1a6e690e1c3143c5713e9306c6e4 (diff)
downloadaur-3483a482231dbdcdc70005a57bf6a8889c0c2be1.tar.gz
package update
-rw-r--r--.SRCINFO9
-rw-r--r--PKGBUILD38
2 files changed, 28 insertions, 19 deletions
diff --git a/.SRCINFO b/.SRCINFO
index db4f32d079b5..1daae7c70c21 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,13 +1,16 @@
pkgbase = python-better-exceptions
pkgdesc = Pretty and helpful exceptions, automatically
pkgver = 0.3.3
- pkgrel = 1
+ pkgrel = 2
url = https://github.com/Qix-/better-exceptions
arch = any
license = MIT
+ makedepends = python-build
+ makedepends = python-installer
makedepends = python-setuptools
+ makedepends = python-wheel
depends = python
- source = https://github.com/Qix-/better-exceptions/archive/0.3.3.tar.gz
- sha512sums = 720cb657a45d5278014720a7aa309a4ee0b6dd014e6058667c09c41a5a69f319993cdb28043ab7b621008267a76fad71d36cc934eee027748db7bf8537659e66
+ source = python-better-exceptions-0.3.3.tar.gz::https://files.pythonhosted.org/packages/source/b/better-exceptions/better_exceptions-0.3.3.tar.gz
+ sha256sums = e4e6bc18444d5f04e6e894b10381e5e921d3d544240418162c7db57e9eb3453b
pkgname = python-better-exceptions
diff --git a/PKGBUILD b/PKGBUILD
index ff5690d6eb23..c63b2dc1c7b0 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,26 +1,32 @@
+# Maintainer: Luis Martinez <luis dot martinez at disroot dot org>
# Contributor: Andrew Steinke <rkcf@rkcf.me>
# Contributor: mdraw.gh at gmail dot com
-_base=better-exceptions
-pkgname=python-${_base}
+
+pkgname=python-better-exceptions
pkgver=0.3.3
-pkgrel=1
+pkgrel=2
pkgdesc="Pretty and helpful exceptions, automatically"
-arch=(any)
-url="https://github.com/Qix-/${_base}"
-license=(MIT)
-depends=(python)
-makedepends=(python-setuptools)
-source=(${url}/archive/${pkgver}.tar.gz)
-sha512sums=('720cb657a45d5278014720a7aa309a4ee0b6dd014e6058667c09c41a5a69f319993cdb28043ab7b621008267a76fad71d36cc934eee027748db7bf8537659e66')
+arch=('any')
+url='https://github.com/Qix-/better-exceptions'
+license=('MIT')
+depends=('python')
+makedepends=('python-build' 'python-installer' 'python-setuptools' 'python-wheel')
+source=("$pkgname-$pkgver.tar.gz::https://files.pythonhosted.org/packages/source/b/better-exceptions/better_exceptions-$pkgver.tar.gz")
+sha256sums=('e4e6bc18444d5f04e6e894b10381e5e921d3d544240418162c7db57e9eb3453b')
build() {
- cd ${_base}-${pkgver}
- export PYTHONHASHSEED=0
- python setup.py build
+ cd "better_exceptions-$pkgver"
+ python -m build --wheel --no-isolation
}
package() {
- cd ${_base}-${pkgver}
- PYTHONPYCACHEPREFIX="${PWD}/.cache/cpython/" python setup.py install --prefix=/usr --root="${pkgdir}" --optimize=1 --skip-build
- install -Dm 644 LICENSE.txt -t "${pkgdir}/usr/share/licenses/${pkgname}"
+ cd "better_exceptions-$pkgver"
+ PYTHONHASHSEED=0 python -m installer --destdir="$pkgdir/" dist/*.whl
+ install -Dm644 README.md -t "$pkgdir/usr/share/doc/$pkgname/"
+
+ local _site="$(python -c 'import site; print(site.getsitepackages()[0])')"
+ install -d "$pkgdir/usr/share/licenses/$pkgname/"
+ ln -s \
+ "$_site/better_exceptions-$pkgver.dist-info/LICENSE.txt" \
+ "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
}