mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-06-09 04:35:18 +02:00
62 lines
1.7 KiB
Text
62 lines
1.7 KiB
Text
# Contributor: Aleks Bunin <alpinelinux@compuix.com>
|
|
# Maintainer: Aleks Bunin <alpinelinux@compuix.com>
|
|
pkgname=delta
|
|
pkgver=0.18.2
|
|
pkgrel=2
|
|
pkgdesc="Syntax-highlighting pager for git and diff output"
|
|
url="https://dandavison.github.io/delta/"
|
|
license="MIT"
|
|
# s390x: incompatible with nix crate
|
|
arch="all !s390x"
|
|
makedepends="
|
|
cargo
|
|
cargo-auditable
|
|
libgit2-dev
|
|
oniguruma-dev
|
|
"
|
|
subpackages="
|
|
$pkgname-bash-completion
|
|
$pkgname-fish-completion
|
|
$pkgname-zsh-completion
|
|
"
|
|
source="$pkgname-$pkgver.tar.gz::https://github.com/dandavison/delta/archive/refs/tags/$pkgver.tar.gz
|
|
libgit2-1.9-compat.patch
|
|
"
|
|
options="net" # cargo fetch
|
|
|
|
# secfixes:
|
|
# 0.13.0-r0:
|
|
# - CVE-2022-24713
|
|
|
|
export RUSTONIG_SYSTEM_LIBONIG="true"
|
|
export LIBGIT2_NO_VENDOR=1 # use system libgit2
|
|
|
|
prepare() {
|
|
default_prepare
|
|
|
|
cargo fetch --target="$CTARGET" --locked
|
|
}
|
|
|
|
build() {
|
|
cargo auditable build --release --frozen
|
|
|
|
local i; for i in bash fish zsh; do
|
|
./target/release/delta --generate-completion $i > target/delta.$i
|
|
done
|
|
}
|
|
|
|
check() {
|
|
cargo test --frozen -- --test-threads=1
|
|
}
|
|
|
|
package() {
|
|
install -Dm755 target/release/delta -t "$pkgdir"/usr/bin/
|
|
install -D -m644 target/delta.bash "$pkgdir"/usr/share/bash-completion/completions/delta
|
|
install -D -m644 target/delta.fish "$pkgdir"/usr/share/fish/vendor_completions.d/delta.fish
|
|
install -D -m644 target/delta.zsh "$pkgdir"/usr/share/zsh/site-functions/_delta
|
|
}
|
|
|
|
sha512sums="
|
|
c096e22e07945f004f4ef8e805d6dfe45ae53a2e9bcb46736f9764d76fcfa556ce1622157ab66021b8fa36a1e322f80fee217e7f3d9d3489ec4df1f8fc61ca67 delta-0.18.2.tar.gz
|
|
4116b4dfa23c5668a4ffcbd5a58f7c662cb01c0a7ca09434f3cffecf167ac6b5242c403837a5ff8464df1daa4bc4da019c9a930939d9e56c2b57c2af068e6c10 libgit2-1.9-compat.patch
|
|
"
|