Date: Thursday, April 6, 2023 @ 14:26:02
  Author: felixonmars
Revision: 1439223

archrelease: copy trunk to community-staging-any

Added:
  python-awesomeversion/repos/community-staging-any/
  python-awesomeversion/repos/community-staging-any/PKGBUILD
    (from rev 1439221, python-awesomeversion/trunk/PKGBUILD)

----------+
 PKGBUILD |   40 ++++++++++++++++++++++++++++++++++++++++
 1 file changed, 40 insertions(+)

Copied: python-awesomeversion/repos/community-staging-any/PKGBUILD (from rev 
1439221, python-awesomeversion/trunk/PKGBUILD)
===================================================================
--- community-staging-any/PKGBUILD                              (rev 0)
+++ community-staging-any/PKGBUILD      2023-04-06 14:26:02 UTC (rev 1439223)
@@ -0,0 +1,40 @@
+# Maintainer: Jelle van der Waa <[email protected]>
+# Contributor: Giovanni Harting <[email protected]>
+
+pkgname=python-awesomeversion
+_name=${pkgname#python-}
+pkgver=22.9.0
+pkgrel=3
+pkgdesc="One version package to rule them all."
+arch=('any')
+url="https://github.com/ludeeus/awesomeversion";
+license=('MIT')
+depends=(python)
+makedepends=(python-build python-installer python-poetry-core)
+checkdepends=('python-pytest')
+source=("$pkgname-$pkgver.tar.gz::https://github.com/ludeeus/$_name/archive/refs/tags/$pkgver.tar.gz";)
+sha512sums=('261849492c5d30b842c14376e065a35cf9ed716cbb7416828694a12a3a2120c922274604815db0953a56ad6bb5cff76276dc26d69aa03bd578321547107ffec1')
+
+prepare() {
+    cd $_name-$pkgver
+    # version = "0"
+    sed -e "s|version = \"0\"|version = \"$pkgver\"|" -i pyproject.toml
+}
+
+check() {
+    cd $_name-$pkgver
+    PYTHONPATH=. pytest tests
+}
+
+build() {
+    cd $_name-$pkgver
+
+    python -m build --wheel --no-isolation
+}
+
+package() {
+    cd $_name-$pkgver
+
+    python -m installer --destdir="$pkgdir" dist/*.whl
+    install -Dm644 LICENCE.md "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
+}

Reply via email to