From 07d8a73022c46dc5b6ee2654eeb18af1e6e2f64c Mon Sep 17 00:00:00 2001 From: i0ntempest Date: Thu, 2 Jul 2026 22:24:01 +0800 Subject: [PATCH] bottom: install man page and completions --- sysutils/bottom/Portfile | 22 +++++++++++++++++++--- 1 file changed, 19 insertions(+), 3 deletions(-) diff --git a/sysutils/bottom/Portfile b/sysutils/bottom/Portfile index d09f67d3e52..1c3c5bc5d6e 100644 --- a/sysutils/bottom/Portfile +++ b/sysutils/bottom/Portfile @@ -6,7 +6,7 @@ PortGroup github 1.0 github.setup ClementTsang bottom 0.14.3 github.tarball_from archive -revision 0 +revision 1 description \ Yet another cross-platform graphical process/system monitor @@ -27,13 +27,29 @@ checksums ${distname}${extract.suffix} \ sha256 dca5cd43313c7d5c48bd78e95c778943a45b3cc0f418c368f9d2fe5b44456fa9 \ size 3518112 +build.env-append BTM_GENERATE=1 + +set exec_name btm + destroot { xinstall -m 0755 \ - ${worksrcpath}/target/[cargo.rust_platform]/release/btm \ + ${worksrcpath}/target/[cargo.rust_platform]/release/${exec_name} \ ${destroot}${prefix}/bin/ + # All supported shells: bash, fish, powershell, zsh, elvish, nushell, fig + set comp_path(bash) ${destroot}${prefix}/share/bash-completion/completions/ + set comp_path(fish) ${destroot}${prefix}/share/fish/vendor_completions.d/ + set comp_path(zsh) ${destroot}${prefix}/share/zsh/site-functions/ + set comp_file(bash) ${exec_name}.bash + set comp_file(fish) ${exec_name}.fish + set comp_file(zsh) _${exec_name} + foreach shell {bash zsh} { + xinstall -d $comp_path(${shell}) + xinstall -m 0644 ${worksrcpath}/target/tmp/${name}/completion/$comp_file(${shell}) $comp_path(${shell}) + } + xinstall -m 0644 ${worksrcpath}/target/tmp/${name}/manpage/${exec_name}.1 ${destroot}${prefix}/share/man/man1 } -notes "${name} is installed as btm" +notes "${name} is installed as ${exec_name}" cargo.crates \ aho-corasick 1.1.4 ddd31a130427c27518df266943a5308ed92d4b226cc639f5a8f1002816174301 \