diff options
Diffstat (limited to 'PKGBUILD')
-rw-r--r-- | PKGBUILD | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/PKGBUILD b/PKGBUILD new file mode 100644 index 000000000000..98582a666be5 --- /dev/null +++ b/PKGBUILD @@ -0,0 +1,38 @@ +# Maintainer: Julien Nicoulaud <julien dot nicoulaud at gmail dot com> + +_pkgname=ncspot +pkgname="${_pkgname}-git" +pkgver=e507364 +pkgrel=1 +pkgdesc="Cross-platform ncurses Spotify client written in Rust, inspired by ncmpc and the likes." +arch=('x86_64') +url="https://github.com/hrkfdn/ncspot" +license=('unknown') +depends=('ncurses' 'openssl') +optdepends=('libpulse: PulseAudio backend' + 'portaudio: PortAUdio backend') +makedepends=('rust' 'cargo') +provides=("${_pkgname}") +conflicts=("${_pkgname}") +source=("git+https://github.com/hrkfdn/ncspot.git") +sha512sums=('SKIP') + +pkgver() { + cd "${srcdir}/${_pkgname}" + git describe --long --tags --always | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g' +} + +build() { + cd "${srcdir}/${_pkgname}" + cargo build --release +} + +check() { + cd "${srcdir}/${_pkgname}" + cargo test --release +} + +package() { + cd "${srcdir}/${_pkgname}" + install -Dm 755 "target/release/${_pkgname}" "${pkgdir}/usr/bin/${_pkgname}" +} |