summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: c12038c03f30d4baa66d54d840c42330054b2fa4 (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
# Maintainer: RiverOnVenus <error@zhui.dev>
pkgname=pispy-git
pkgver=0.9.0.r0.g0fe67fc
pkgrel=1
pkgdesc='A terminal-based tool for looking up stuff in PyPI'
url="https://github.com/davep/pispy"
arch=('any')
license=('GPL-3.0-only')
depends=('python' 'python-httpx' 'python-textual' 'python-typing_extensions' 'python-packaging')
makedepends=('git' 'python-build' 'python-installer' 'python-wheel' 'python-setuptools' 'python-hatchling')
provides=('pispy')
conflicts=('pispy')
source=("$pkgname"::"git+${url}")
sha256sums=('SKIP')

pkgver() {
  cd $pkgname
  git describe --long --tags --abbrev=7 | sed 's/^v//;s/-/.r/;s/-/./'
}

prepare(){
  cd $pkgname
  git clean -dfx
}

build() {
    cd $pkgname
    python -m build --wheel --no-isolation
}

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