summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 7655f57027f068d717f7a89bf5ecaf8c15d7254a (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
# Maintainer: Cyrinux <pkgbuilds AT levis DOT name>

pkgname=mpdmenu-git
_gitname=mpdmenu
pkgver=r18.c52189a
pkgrel=3
pkgdesc="Simple dmenu frontend for MPD"
license=(MIT)
url=https://github.com/arikai/mpdmenu
depends=('dmenu' 'python-mpd2')
optdepends=('mpd')
arch=(any)
makedepends=(git)
conflicts=(mpdmenu)
provides=(mpdmenu)
source=('git+https://github.com/arikai/mpdmenu.git')
md5sums=('SKIP')

pkgver() {
    cd "${srcdir}/mpdmenu"
    # printf '%d.%s\n' "$(date -u -d "@$(git log -1 --format="%ct")" +%Y%m%d%H%M%S)" "$(git rev-parse --short HEAD)"
    printf "r%s.%s" "$(git rev-list --count HEAD)" "$(git rev-parse --short HEAD)"
}

package() {
    cd "${srcdir}/mpdmenu"
    install -D -m0755 \
        "${srcdir}/mpdmenu/mpdmenu.py" \
        "$pkgdir/usr/bin/mpdmenu"
}