summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 15b058fad6cdf49ad24dcd67a8a5d2a17d55270c (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: haxibami <contact at haxibami dot net>

pkgname=python-pygnuutils
_pkgname="${pkgname#python-}"
pkgver=0.1.1
pkgrel=1
pkgdesc='Pure python implementation for GNU utils'
arch=('any')
url='https://github.com/matan1008/pygnuutils'
license=('GPL3')
depends=('python' 'python-click')
makedepends=('python-build' 'python-wheel' 'python-installer' 'python-setuptools')
checkdepends=('python-pytest')
source=("${pkgname}-${pkgver}.tar.gz::${url}/archive/refs/tags/v${pkgver}.tar.gz")
sha256sums=('7607e8d51b3315f2ff48df131670ca33507ea5509c1f18d62e338ec2959dc839')

build() {
  cd "${srcdir}/${_pkgname}-${pkgver}"
  python -m build --wheel --no-isolation
}

check() {
  cd "${srcdir}/${_pkgname}-${pkgver}"
  python -m pytest
}

package() {
  cd "${srcdir}/${_pkgname}-${pkgver}"
  python -m installer --destdir="$pkgdir" dist/*.whl
  install -Dm644 LICENSE "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}