diff options
author | xiota | 2024-04-03 01:00:42 +0000 |
---|---|---|
committer | xiota | 2024-04-03 01:00:42 +0000 |
commit | 5648c57f1fdd4afb185711d3c806b84804e661c3 (patch) | |
tree | e9787fad6760b41d77c67fe006a6db288f6f4368 | |
download | aur-5648c57f1fdd4afb185711d3c806b84804e661c3.tar.gz |
0.5.r21
-rw-r--r-- | .SRCINFO | 22 | ||||
-rw-r--r-- | .gitignore | 4 | ||||
-rw-r--r-- | PKGBUILD | 68 |
3 files changed, 94 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO new file mode 100644 index 000000000000..bda316aca625 --- /dev/null +++ b/.SRCINFO @@ -0,0 +1,22 @@ +pkgbase = python-iniparse-git + pkgdesc = Better INI parser library for Python + pkgver = 0.5.r21.gdbfd717 + pkgrel = 1 + url = https://github.com/candlepin/python-iniparse + arch = any + license = MIT + checkdepends = python-tests + makedepends = git + makedepends = python-build + makedepends = python-installer + makedepends = python-setuptools + makedepends = python-wheel + depends = python + provides = python-iniparse=0.5 + conflicts = python-iniparse + source = candlepin.python-iniparse::git+https://github.com/candlepin/python-iniparse.git + source = 29_fix_tests.patch::https://github.com/candlepin/python-iniparse/pull/29.diff + sha256sums = SKIP + sha256sums = bbd488275c73583591dcc997993834240e2f45878a1c3ce4972cd82b5b1d925b + +pkgname = python-iniparse-git diff --git a/.gitignore b/.gitignore new file mode 100644 index 000000000000..018a3de08144 --- /dev/null +++ b/.gitignore @@ -0,0 +1,4 @@ +* +!PKGBUILD +!.SRCINFO +!.gitignore diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..66f6d135358d --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,68 @@ +# Maintainer: + +_module="iniparse" +_pkgname="python-$_module" +pkgname="$_pkgname-git" +pkgver=0.5.r21.gdbfd717 +pkgrel=1 +pkgdesc="Better INI parser library for Python" +url="https://github.com/candlepin/python-iniparse" +license=('MIT') +arch=('any') + +depends=( + 'python' +) +makedepends=( + 'git' + 'python-build' + 'python-installer' + 'python-setuptools' + 'python-wheel' +) +checkdepends=( + 'python-tests' +) + +provides=("$_pkgname=${pkgver%%.r*}") +conflicts=("$_pkgname") + +_pkgsrc="candlepin.python-iniparse" +source=( + "$_pkgsrc"::"git+$url.git" + "29_fix_tests.patch"::"https://github.com/candlepin/python-iniparse/pull/29.diff" +) +sha256sums=( + 'SKIP' + 'bbd488275c73583591dcc997993834240e2f45878a1c3ce4972cd82b5b1d925b' +) + +prepare() { + cd "$_pkgsrc" + patch -Np1 -i ../29_fix_tests.patch +} + +pkgver() { + cd "$_pkgsrc" + git describe --long --tags --abbrev=7 \ + | sed -E 's/^[^0-9]*//;s/([^-]*-g)/r\1/;s/-/./g' +} + +build() { + cd "$_pkgsrc" + python -m build --no-isolation --wheel +} + +check() { + cd "$_pkgsrc" + python runtests.py +} + +package() { + cd "$_pkgsrc" + python -m installer --destdir="$pkgdir" "$(ls -1 dist/*.whl | sort -rV | head -1)" + + install -Dm644 "LICENSE" -t "$pkgdir/usr/share/licenses/$pkgname/" + + rm -rf "$pkgdir/usr/share/doc" +} |