summarylogtreecommitdiffstats
diff options
context:
space:
mode:
author0x9fff002024-02-25 02:55:09 +0100
committer0x9fff002024-02-25 02:55:09 +0100
commita88e944507b380b8ab73da598685e765ef7cc151 (patch)
tree9506ad6a9deb61a572d073733f49324aaf44b416
parente24404cd3c364ce82b6021102e68f8f83a24d609 (diff)
downloadaur-a88e944507b380b8ab73da598685e765ef7cc151.tar.gz
1.2.22-2
* update to SPDX license identifier * switch to git source to avoid unstable tarball hash
-rw-r--r--.SRCINFO9
-rw-r--r--.gitignore1
-rw-r--r--.gitignore_append1
-rw-r--r--PKGBUILD23
4 files changed, 21 insertions, 13 deletions
diff --git a/.SRCINFO b/.SRCINFO
index acc9142d364d..8582440f343d 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,10 +1,11 @@
pkgbase = python-pymctranslate
pkgdesc = A library of block mappings that can be used to convert from any Minecraft format into any other Minecraft format
pkgver = 1.2.22
- pkgrel = 1
+ pkgrel = 2
url = https://github.com/gentlegiantJGC/PyMCTranslate
arch = any
- license = custom
+ license = LicenseRef-Amulet-Team-1.0.0
+ makedepends = git
makedepends = python-build
makedepends = python-installer
makedepends = python-setuptools
@@ -13,7 +14,7 @@ pkgbase = python-pymctranslate
depends = python
depends = python-amulet-nbt
depends = python-numpy
- source = python-pymctranslate-1.2.22.tar.gz::https://github.com/gentlegiantJGC/PyMCTranslate/archive/1.2.22.tar.gz
- sha256sums = bac61b0b01f38cba5c69210c86ce1843e66da6de622997fab850f00694d6f380
+ source = git+https://github.com/gentlegiantJGC/PyMCTranslate.git#commit=c50c2671d0fa63e0c3fedaac39e36f30ceaa51a2
+ sha256sums = SKIP
pkgname = python-pymctranslate
diff --git a/.gitignore b/.gitignore
index f12030797c07..7da4dce45dfb 100644
--- a/.gitignore
+++ b/.gitignore
@@ -25,3 +25,4 @@ src/
# .nfs files are created when an open file is removed but is still being accessed
.nfs*
# archlinuxpackages linux
+PyMCTranslate
diff --git a/.gitignore_append b/.gitignore_append
index a92184e5a9bf..e4d26308efe8 100644
--- a/.gitignore_append
+++ b/.gitignore_append
@@ -1 +1,2 @@
# archlinuxpackages linux
+PyMCTranslate
diff --git a/PKGBUILD b/PKGBUILD
index eefc8fda449d..dc126ae454ac 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -3,38 +3,43 @@
_name=PyMCTranslate
pkgname=python-${_name,,}
pkgver=1.2.22
-pkgrel=1
+_commit=c50c2671d0fa63e0c3fedaac39e36f30ceaa51a2
+pkgrel=2
pkgdesc='A library of block mappings that can be used to convert from any Minecraft format into any other Minecraft format'
arch=('any')
url="https://github.com/gentlegiantJGC/$_name"
-license=('custom')
+license=('LicenseRef-Amulet-Team-1.0.0')
depends=('python' 'python-amulet-nbt' 'python-numpy')
-makedepends=('python-build' 'python-installer' 'python-setuptools' 'python-versioneer' 'python-wheel')
+makedepends=('git' 'python-build' 'python-installer' 'python-setuptools' 'python-versioneer' 'python-wheel')
# tests directory isn't in pypi sdist
-source=("$pkgname-$pkgver.tar.gz::$url/archive/$pkgver.tar.gz")
-sha256sums=('bac61b0b01f38cba5c69210c86ce1843e66da6de622997fab850f00694d6f380')
+# github tarball has unstable hash due to https://github.com/gentlegiantJGC/PyMCTranslate/blob/45024a6ca12592913e6249269d8a180b2940f6aa/PyMCTranslate/_version.py#L25
+source=("git+$url.git#commit=$_commit")
+sha256sums=('SKIP')
prepare() {
- cd "$_name-$pkgver"
+ cd "$_name"
+
+ # expand placeholders
+ git archive --format tar HEAD PyMCTranslate/_version.py | tar -x
# use current versioneer
sed -Ei 's/(versioneer)-518/\1/' pyproject.toml
}
build() {
- cd "$_name-$pkgver"
+ cd "$_name"
python -m build --wheel --no-isolation
}
check() {
- cd "$_name-$pkgver"
+ cd "$_name"
python -m unittest discover -s tests
}
package() {
- cd "$_name-$pkgver"
+ cd "$_name"
python -m installer --destdir="$pkgdir" dist/*.whl