summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: a47df646fabf9f77ac1fc785579f3096c65850b2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
# Maintainer: Carl Smedstad <carl.smedstad at protonmail dot com>
# Contributor: Andrew Sun <adsun701 at gmail dot com>
# Contributor: Alex Zose <alexander[dot]zosimidis[at]gmail[dot]com>

pkgname=crudini
pkgver=0.9.5
pkgrel=2
pkgdesc="A utility for manipulating ini files"
arch=(any)
url="https://github.com/pixelb/crudini"
license=(GPL-2.0-only)
depends=(
  python
  python-iniparse
)
makedepends=(
  python-build
  python-installer
  python-setuptools
  python-setuptools-scm
  python-wheel
)

source=("$pkgname-$pkgver.tar.gz::$url/archive/refs/tags/$pkgver.tar.gz")
sha256sums=('b0492cb9ce126ce3c05ae7d8424c0fca5b26a788f593afe000150ba0c4b23cdb')

_archive="$pkgname-$pkgver"

build() {
  cd "$_archive"

  export SETUPTOOLS_SCM_PRETEND_VERSION=$pkgver
  python -m build --wheel --no-isolation
}

check() {
  cd "$_archive"

  cd tests
  ./test.sh
}

package() {
  cd "$_archive"

  python -m installer --destdir="$pkgdir" dist/*.whl
}