blob: 942f866e4f8643b74efe3ce92466b9c44ffbe2b0 (
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
|
# Maintainer: erayaydin <erayaydinn@protonmail.com>
# Maintainer: jojii <jojii@gmx.net>
pkgname=earbuds-xdg-git
_pkgname=earbuds
_gitname=LiveBudsCli
pkgver=v0.1.9.r19.g4a2d75f
pkgrel=1
pkgdesc="Control your galaxy buds live via cli w/ XDG Base Directory support"
url="https://github.com/JojiiOfficial/LiveBudsCli"
license=("GPL3")
source=(
"git+$url"
'xdg.patch'
)
md5sums=(
'SKIP'
'e5d31b44912bc1450ae46490508d15a2'
)
arch=("x86_64")
conflicts=("earbuds" "earbuds-git")
provides=("earbuds" "earbuds-git")
makedepends=("cargo" "git" "bluez" "bluez-libs" "gcc-libs" "glibc")
pkgver() {
cd $_gitname
git describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g'
}
prepare() {
patch --directory="$_gitname" --forward --strip=1 --input="${srcdir}/xdg.patch"
}
build() {
cd $_gitname
cargo build --release
}
package() {
cd $_gitname
usrdir="$pkgdir/usr"
mkdir -p $usrdir
install -Dm 755 "target/release/${_pkgname}" "${pkgdir}/usr/bin/${_pkgname}"
install -Dm 755 "LICENSE" "${pkgdir}/usr/share/licenses/${_pkgname}/LICENSE"
./target/release/${_pkgname} --generate=zsh > _${_pkgname}
install -Dm 644 _earbuds "${pkgdir}/usr/share/zsh/site-functions/_${_pkgname}"
./target/release/${_pkgname} --generate=bash > ${_pkgname}.fish
install -Dm 644 ${_pkgname}.fish "${pkgdir}/usr/share/fish/vendor_completions.d/${_pkgname}.fish"
}
|