# Contributor: Jakub Jirutka # Maintainer: Jakub Jirutka pkgname=git-branchless pkgver=0.7.1 pkgrel=3 pkgdesc="Suite of tools to help you visualize, navigate, manipulate, and repair your commit graph" url="https://github.com/arxanas/git-branchless" arch="aarch64 armhf armv7 ppc64le x86 x86_64" # blocked by rust/cargo license="GPL-2.0-only" makedepends=" cargo cargo-auditable libgit2-dev libssh2-dev openssl-dev>3 sqlite-dev " checkdepends=" bash git " source="https://github.com/arxanas/git-branchless/archive/v$pkgver/git-branchless-$pkgver.tar.gz getrandom.patch libgit2.patch unbundle-sqlite.patch " options="net" export LIBSSH2_SYS_USE_PKG_CONFIG=1 # use system libssh2 prepare() { default_prepare # Rust target triple. local target=$(rustc -vV | sed -n 's/host: //p') # Build against system-provided libs mkdir -p .cargo cat >> .cargo/config.toml <<-EOF [target.$target] git2 = { rustc-link-lib = ["git2"] } EOF # open64 cargo update -p getrandom --precise 0.2.10 cargo fetch --target="$CTARGET" --locked } build() { cargo auditable build --frozen --release } check() { # NOTE: The first two skipped tests hang on CI, see # https://github.com/arxanas/git-branchless/pull/159 for more info. # The other two are probably broken. TEST_GIT_EXEC_PATH=$(git --exec-path) \ TEST_GIT=$(which git) \ RUST_BACKTRACE=1 \ cargo test --workspace --frozen -- \ --skip=test_checkout_pty \ --skip=test_next_ambiguous_interactive \ --skip=command::test_test::test_test_config_strategy \ --skip=command::test_test::test_test_verbosity } package() { install -D -m755 target/release/git-branchless -t "$pkgdir"/usr/bin/ } sha512sums=" c556d3e72ee13ce4ab6600a64a4b20788234176c89107b57dfccd69ac72027bfed126c1bf3dc71d075b71bc13d88c696700da320e0795e3f737000c6a1f651c4 git-branchless-0.7.1.tar.gz d9c4e44f19bfcf2b979eca0ba3f022791566e61fdfc1cfe6eadeb1c34894aba072a634b9e62ab4a7d342b9885526487b3629dae90603ef4c70b23315c66200c1 getrandom.patch 3630b78ae2191104f31ce5b797ca392a08b6e89e200f1c1487b1a4d0cce29b4c8ebc89f824470966ae55793bbb6ff7945d9a4d62c327d2898c81a1e67765438f libgit2.patch ebee160cd936b151515609d9c972c0b747d3bb122bfc0cb6946e3ade86e521efdf1277b033fcf76ecd60f4e81fcfa0f233db1eb2da7ad800d30f7a938cf5ba2f unbundle-sqlite.patch "