summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 67d62d1a1a8fba6b3c72ffb4de26518a2e60b7a9 (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
# Maintainer: Akatsuki Rui <akiirui@outlook.com>

pkgname="mpv-handler-git"
_pkgname=${pkgname%-git}
pkgver=2020.11.19.r3.gac2a68d
pkgrel=1
pkgdesc="Play website videos and songs with mpv & youtube-dl."
arch=("any")
depends=("mpv" "youtube-dl")
makedepends=("git")
url="https://github.com/akiirui/mpv-handler/"
license=("MIT")
source=("git+https://github.com/akiirui/mpv-handler.git")
b2sums=("SKIP")

pkgver() {
  cd "${srcdir}/$_pkgname"
  git describe --long --tags | sed "s/\([^-]*-g\)/r\1/;s/-/./g"
}

package() {
  cd "${srcdir}/${_pkgname}"
  install -D -m 755 linux/mpv-handler "${pkgdir}/usr/bin/mpv-handler"
  install -D -m 644 linux/mpv-handler.desktop "${pkgdir}/usr/share/applications/mpv-handler.desktop"

  install -D -m 644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
}