mirror of
https://github.com/SinTan1729/lure-repo.git
synced 2024-12-25 22:38:36 -06:00
chg: Use the helper functions for bat
This commit is contained in:
parent
6e4b13ea58
commit
b4360dc624
1 changed files with 6 additions and 7 deletions
13
bat/lure.sh
13
bat/lure.sh
|
@ -14,7 +14,7 @@ sources=()
|
||||||
checksums=()
|
checksums=()
|
||||||
|
|
||||||
version() {
|
version() {
|
||||||
printf "$(curl -sL "https://api.github.com/repos/${git_repo}/releases/latest" | jq -r '.tag_name')"
|
printf "$(curl -sL "https://api.github.com/repos/${git_repo}/releases/latest" | jq -r '.tag_name')"
|
||||||
}
|
}
|
||||||
|
|
||||||
package() {
|
package() {
|
||||||
|
@ -26,12 +26,11 @@ package() {
|
||||||
tar -xzf "${name}.tar.gz" -C .
|
tar -xzf "${name}.tar.gz" -C .
|
||||||
cd "./${name}-${version}-x86_64-unknown-linux-musl"
|
cd "./${name}-${version}-x86_64-unknown-linux-musl"
|
||||||
# Binary
|
# Binary
|
||||||
install -Dm755 "./${name}" "${pkgdir}/usr/bin/${name}"
|
install-binary "./${name}"
|
||||||
# Manpage
|
# Manpage
|
||||||
install -Dm644 "./${name}.1" "${pkgdir}/usr/share/man/man1/${name}.1"
|
install-manual "./${name}.1"
|
||||||
# Autocomplete
|
# Autocomplete
|
||||||
command -v fish &> /dev/null && install -Dm644 "./autocomplete/${name}.fish" "${pkgdir}/usr/share/fish/completions/${name}.fish"
|
install-completion fish <"./autocomplete/${name}.fish"
|
||||||
command -v zsh &> /dev/null && install -Dm644 "./autocomplete/${name}.zsh" "${pkgdir}/usr/share/zsh/site-functions/_${name}"
|
install-completion zsh "./autocomplete/${name}.zsh"
|
||||||
command -v bash &> /dev/null && install -Dm644 "./autocomplete/${name}.bash" "${pkgdir}/usr/share/bash-completion/completions/${name}"
|
install-completion bash "./autocomplete/${name}.bash"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue