0
0
mirror of https://github.com/termux/termux-packages.git synced 2024-12-11 23:00:52 +00:00
Termux Github Actions e4e8be6410 bump(main/broot): 1.44.2
This commit has been automatically submitted by Github Actions.
2024-10-22 12:15:04 +00:00

41 lines
1.3 KiB
Bash

TERMUX_PKG_HOMEPAGE=https://github.com/Canop/broot
TERMUX_PKG_DESCRIPTION="A better way to navigate directories"
TERMUX_PKG_LICENSE="MIT"
TERMUX_PKG_MAINTAINER="@termux"
TERMUX_PKG_VERSION="1.44.2"
TERMUX_PKG_SRCURL=https://github.com/Canop/broot/archive/refs/tags/v${TERMUX_PKG_VERSION}.tar.gz
TERMUX_PKG_SHA256=e1b78354c21680914a07ed4b856257c83ef873b878ef281bd2d1aed7fcba3828
TERMUX_PKG_DEPENDS="libgit2"
TERMUX_PKG_BUILD_IN_SRC=true
TERMUX_PKG_AUTO_UPDATE=true
termux_step_pre_configure() {
termux_setup_rust
: "${CARGO_HOME:=$HOME/.cargo}"
export CARGO_HOME
cargo fetch --target "${CARGO_TARGET_NAME}"
local f
for f in $CARGO_HOME/registry/src/*/libgit2-sys-*/build.rs; do
sed -i -E 's/\.range_version\(([^)]*)\.\.[^)]*\)/.atleast_version(\1)/g' "${f}"
done
sed -i '/trash/d' $TERMUX_PKG_SRCDIR/Cargo.toml
}
termux_step_make() {
cargo build --jobs $TERMUX_PKG_MAKE_PROCESSES --target $CARGO_TARGET_NAME --release
mkdir -p build
cp man/page build/broot.1
sed -i "s/#version/$TERMUX_PKG_VERSION/g" build/broot.1
sed -i "s/#date/$(date -r man/page +'%Y\/%m\/%d')/g" build/broot.1
}
termux_step_make_install() {
install -Dm755 -t $TERMUX_PREFIX/bin target/${CARGO_TARGET_NAME}/release/broot
install -Dm644 -t $TERMUX_PREFIX/share/man/man1 build/broot.1
}