summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 1232acf5148150141d2ea8611df9dbf2956b4412 (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
# Maintainer: Fabrix Xm <fabrix.xm@gmail.com>
_pkgname=hazwaz
pkgname=python-$_pkgname
pkgver=0.0.3
pkgrel=2
pkgdesc="A python library to write command line scripts"
arch=('any')
url="https://hazwaz.trueelena.org/"
license=(AGPL-3.0-or-later)
depends=('python')
optdepends=('python-coloredlogs: pretty log output')
makedepends=(python-build python-installer python-wheel)
source=("https://git.sr.ht/~valhalla/$_pkgname/archive/v$pkgver.tar.gz" pyproject.toml.patch)
sha256sums=('b71a79e91d4e9420bcc29d67d1b8db26d54954a702ecd0a62d7754a90158fb57'
            'e044804dd39fd283e421b3387462d9faa75cf429b304576a63982393cba64bd4')

prepare() {
  cd "${_pkgname}-v${pkgver}"
  # patch pyproject to not require setuptools-scm to get version
  patch --forward --strip=1 --input=../pyproject.toml.patch
}

build() {
  cd "${_pkgname}-v${pkgver}"
  python -m build -w --skip-dependency-check --no-isolation 
}

package() {
  cd "${_pkgname}-v${pkgver}"
  python -m installer --destdir="$pkgdir" dist/*.whl
}