summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: a6ded8db8444868d1affd856a4b5b131b8904741 (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
# Maintainer: Bill Sideris <bill88t@bredos.org>

pkgname=nhentai-git
pkgver=r669.d74fd10
pkgrel=1
pkgdesc='CLI tool for downloading doujinshi from nhentai.net'
arch=(any)
url=https://github.com/RicterZ/"${pkgname%-*}"
license=('MIT')

depends=(python-requests python-soupsieve python-beautifulsoup4 python-tabulate python-iso8601 python-httpx python-pip)
makedepends=(git python-build python-installer python-wheel python-poetry)

provides=({,python-}"${pkgname%-*}")
conflicts=("${provides[@]}" python-$pkgname)
source=(git+https://github.com/RicterZ/"${pkgname%-*}".git)
md5sums=(SKIP)

pkgver() {
  cd "$srcdir/${pkgname%-*}"
  printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}

build() {
  cd "$srcdir/${pkgname%-*}"
  python -m build --wheel --no-isolation
}

package() {
  cd "$srcdir/${pkgname%-*}"
  python -m installer --destdir="$pkgdir" dist/*.whl
}