summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-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 1a172d33c123..579b6d5bf95b 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,11 +1,12 @@
pkgbase = python-amulet-nbt
pkgdesc = A Python and Cython library for reading and writing binary NBT and stringified NBT
- pkgver = 2.1.2
+ pkgver = 2.1.3
pkgrel = 1
url = https://github.com/Amulet-Team/Amulet-NBT
arch = x86_64
- license = custom
+ license = LicenseRef-Amulet-Team-1.0.0
makedepends = cython
+ makedepends = git
makedepends = python-build
makedepends = python-installer
makedepends = python-setuptools
@@ -14,7 +15,7 @@ pkgbase = python-amulet-nbt
depends = python
depends = python-mutf8
depends = python-numpy
- source = python-amulet-nbt-2.1.2.tar.gz::https://github.com/Amulet-Team/Amulet-NBT/archive/2.1.2.tar.gz
- sha256sums = efefff4b3d29e44c9fee6b30c37d7f68c22c397f88bcd8a6bb671a19add038fd
+ source = git+https://github.com/Amulet-Team/Amulet-NBT.git#commit=06f49526d9a4425205941471b5d614f687c42756
+ sha256sums = SKIP
pkgname = python-amulet-nbt
diff --git a/.gitignore b/.gitignore
index f12030797c07..3b82011957d8 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
+Amulet-NBT
diff --git a/.gitignore_append b/.gitignore_append
index a92184e5a9bf..c8a3ab2bd2fe 100644
--- a/.gitignore_append
+++ b/.gitignore_append
@@ -1 +1,2 @@
# archlinuxpackages linux
+Amulet-NBT
diff --git a/PKGBUILD b/PKGBUILD
index 7e98982dee5c..cdff46b5b8c9 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -4,33 +4,38 @@ _name=Amulet-NBT
_lowername=${_name,,}
_pyname=${_lowername/-/_}
pkgname=python-$_lowername
-pkgver=2.1.2
+pkgver=2.1.3
+_commit=06f49526d9a4425205941471b5d614f687c42756
pkgrel=1
pkgdesc='A Python and Cython library for reading and writing binary NBT and stringified NBT'
arch=('x86_64')
url="https://github.com/Amulet-Team/$_name"
-license=('custom')
+license=('LicenseRef-Amulet-Team-1.0.0')
depends=('python' 'python-mutf8' 'python-numpy')
-makedepends=('cython' 'python-build' 'python-installer' 'python-setuptools' 'python-versioneer' 'python-wheel')
+makedepends=('cython' '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=('efefff4b3d29e44c9fee6b30c37d7f68c22c397f88bcd8a6bb671a19add038fd')
+# github tarball has unstable hash due to https://github.com/Amulet-Team/Amulet-NBT/blob/61cb6fe0c614b95ee75868ff85677284e2b3cb74/amulet_nbt/_version.py#L27
+source=("git+$url.git#commit=$_commit")
+sha256sums=('SKIP')
prepare() {
- cd "$_name-$pkgver"
+ cd "$_name"
+
+ # expand placeholders
+ git archive --format tar HEAD amulet_nbt/_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"
# based on https://wiki.archlinux.org/title/Python_package_guidelines#Check
# build directory needs to be before script directory
@@ -38,7 +43,7 @@ check() {
}
package() {
- cd "$_name-$pkgver"
+ cd "$_name"
python -m installer --destdir="$pkgdir" dist/*.whl