summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 2f8cf10a2589db65f21e2922df151187d6e7b55b (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
# Maintainer: Nazar Vinnichuk <nazar.vinnichuk at tutanota dot com>
pkgname=barva-git
_pkgname=${pkgname%-git}
pkgver=0.5.r7.gcd92f9f
pkgrel=1
pkgdesc="An audio visualizer that pulses the background of your terminal."
url="http://github.com/Kharacternyk/${_pkgname}"
arch=('any')
license=('GPL3')
depends=('pulseaudio')
makedepends=('git')
conflicts=("${_pkgname}")
source=("${_pkgname}::git+https://github.com/Kharacternyk/${_pkgname}.git#branch=master")
sha256sums=(SKIP)

pkgver() {
    cd "${srcdir}/${_pkgname}"
    local _version="$(git describe --tags --match 'v*' | sed 's/-/.r/' | sed 's/-/./')"
    printf "${_version#v}"
}

build() {
    cd "${_pkgname}/src"
    make
}

package() {
    cd "${srcdir}/${_pkgname}"
    install -Dm755 barva "${pkgdir}/usr/bin/barva"
    install -Dm644 README.rst "${pkgdir}/usr/share/doc/${_pkgname}/README.rst"

    cd scripts
    for _SCRIPT in *; do
        install -Dm755 "$_SCRIPT" "${pkgdir}/usr/share/${_pkgname}/${_SCRIPT}"
    done

}