summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 4596cf49bdd35b0984dc3ab97730802b8be44337 (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
# Maintainer: Scott Hansen (firecat53) tech at firecat53 dot net
pkgname=urlscan-git
_gitname=urlscan
pkgver=r251.1c15a8c
pkgrel=1
pkgdesc="Replacement for urlview with html context and other improvements."
arch=('any')
url="https://github.com/firecat53/urlscan"
license=('GPL-2.0-or-later')
conflicts=('urlscan')
provides=('urlscan')
depends=('python' 'python-urwid')
makedepends=('git' 'python-build' 'python-installer' 'python-hatchling')
optdepends=('xdg-utils: open URLs with the default browser'
            'xsel: clipboard support (X11)'
            'xclip: clipboard support (X11)'
            'wl-clipboard: clipboard support (Wayland)')
source=('git+https://github.com/firecat53/urlscan.git')
md5sums=('SKIP')
install=urlscan.install

prepare() {
  git -C "$_gitname" clean -dfx
}

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

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

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