mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2026-05-05 12:26:52 +02:00
testing/git-branchless: new aport
This commit is contained in:
parent
b82130dbc7
commit
d89a7e18d1
65
testing/git-branchless/APKBUILD
Normal file
65
testing/git-branchless/APKBUILD
Normal file
@ -0,0 +1,65 @@
|
||||
# Contributor: Jakub Jirutka <jakub@jirutka.cz>
|
||||
# Maintainer: Jakub Jirutka <jakub@jirutka.cz>
|
||||
pkgname=git-branchless
|
||||
pkgver=0.3.8
|
||||
pkgrel=0
|
||||
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
|
||||
libgit2-dev
|
||||
libssh2-dev
|
||||
openssl-dev
|
||||
sqlite-dev
|
||||
"
|
||||
checkdepends="git"
|
||||
subpackages="$pkgname-doc"
|
||||
source="https://github.com/arxanas/git-branchless/archive/v$pkgver/git-branchless-$pkgver.tar.gz
|
||||
unbundle-sqlite.patch
|
||||
"
|
||||
|
||||
export LIBSSH2_SYS_USE_PKG_CONFIG=1 # use system libssh2
|
||||
|
||||
prepare() {
|
||||
default_prepare
|
||||
|
||||
# Optimize binary for size.
|
||||
cat >> Cargo.toml <<-EOF
|
||||
|
||||
[profile.release]
|
||||
codegen-units = 1
|
||||
lto = true
|
||||
opt-level = "z"
|
||||
panic = "abort"
|
||||
EOF
|
||||
cargo fetch --locked
|
||||
}
|
||||
|
||||
build() {
|
||||
cargo build --frozen --release
|
||||
}
|
||||
|
||||
check() {
|
||||
# NOTE: Skipped tests hang on CI, see
|
||||
# https://github.com/arxanas/git-branchless/pull/159 for more info.
|
||||
GIT_EXEC_PATH=$(git --exec-path) \
|
||||
PATH_TO_GIT=$(which git) \
|
||||
RUST_BACKTRACE=1 \
|
||||
cargo test --frozen -- \
|
||||
--skip=test_checkout_pty \
|
||||
--skip=test_next_ambiguous_interactive
|
||||
}
|
||||
|
||||
package() {
|
||||
install -D -m755 target/release/git-branchless -t "$pkgdir"/usr/bin/
|
||||
|
||||
install -d -m755 "$pkgdir"/usr/share/man
|
||||
cp -r ./target/release/build/git-branchless-*/out/man1/man* "$pkgdir"/usr/share/man/
|
||||
}
|
||||
|
||||
sha512sums="
|
||||
922f918a504b20d72743576eeeff58d54c976a5eb2f937093b4c4af327f39f76cfde76d1310b3d1713c1668fe6261bd32e3666cd36e52c48c3d5c7ac31fef90d git-branchless-0.3.8.tar.gz
|
||||
b012bcbed41a7a4848df98eda55d8182609d1bfd0aeb133249d9d5695e5b1a7df1a087754526e0ca6498a84ebb1e78513e554cc40b1d1950ca517e77b62c7907 unbundle-sqlite.patch
|
||||
"
|
||||
21
testing/git-branchless/unbundle-sqlite.patch
Normal file
21
testing/git-branchless/unbundle-sqlite.patch
Normal file
@ -0,0 +1,21 @@
|
||||
--- a/Cargo.toml
|
||||
+++ b/Cargo.toml
|
||||
@@ -68,7 +68,7 @@
|
||||
path-slash = "0.1.4"
|
||||
rayon = "1.5.1"
|
||||
regex = "1.5.4"
|
||||
-rusqlite = { version = "0.26.1", features = ["bundled"] }
|
||||
+rusqlite = { version = "0.26.1" }
|
||||
tempfile = "3.2.0"
|
||||
textwrap = "0.14.2"
|
||||
tracing = "0.1.26"
|
||||
--- a/Cargo.lock
|
||||
+++ b/Cargo.lock
|
||||
@@ -1284,7 +1284,6 @@
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "abd5850c449b40bacb498b2bbdfaff648b1b055630073ba8db499caf2d0ea9f2"
|
||||
dependencies = [
|
||||
- "cc",
|
||||
"pkg-config",
|
||||
"vcpkg",
|
||||
]
|
||||
Loading…
x
Reference in New Issue
Block a user