makedeb


python3-mov-cli-anime-git 1.1.4.r1.868fa5b-1


A mov-cli v4 plugin for watching anime.

Viewing /PKGBUILD.

View raw.

Click here to go back to the Git tree for python3-mov-cli-anime-git.

# Maintainer: exponential <echo ZXhwb25lbnRpYWxtYXRyaXhAcHJvdG9ubWFpbC5jb20K | base64 -d>
_pkgname=mov-cli-anime
pkgname=python3-mov-cli-anime-git
pkgver=1.1.4.r1.868fa5b
pkgrel=1
pkgdesc="A mov-cli v4 plugin for watching anime."
arch=('all')
license=('MIT')
depends=('python3-requests')
makedepends=('git' 'python3-build' 'python3-installer' 'python3-wheel')
source=("git+https://github.com/mov-cli/mov-cli-anime")
b2sums=(SKIP)
provides=('python3-mov-cli-anime')
conflicts=('python3-mov-cli-anime')

pkgver() {
  cd "$srcdir/${_pkgname}"
  printf "%s.r%s.%s" "$(grep __version__ otaku_watcher/__init__.py | cut -d '"' -f 2)" "$(git rev-list --count HEAD)" "$(git describe --long --always | sed 's/\([^-]*-g\)/r\1/;s/-/./g')"
}

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

package() {
  cd $srcdir/${_pkgname}
  python3 -m installer --destdir="$pkgdir" dist/*.whl #--optimize=1 --skip-build
  # Manual remove local
  mv "$pkgdir/usr/local/"* "$pkgdir/usr/"
  rmdir "$pkgdir/usr/local" 
  #doc
  install -Dm644 "README.md" "$pkgdir/usr/share/doc/$_pkgname/readme"
  install -Dm644 LICENSE "$pkgdir/usr/share/doc/$_pkgname/"
}