wok-current annotate tmux-mem-cpu-load/receipt @ rev 25009
updated ocaml (4.10.0 -> 4.14.0)
author | Hans-G?nter Theisgen |
---|---|
date | Mon May 16 17:27:45 2022 +0100 (2022-05-16) |
parents | 55085cfd39e0 |
children | a73375793791 |
rev | line source |
---|---|
pascal@15723 | 1 # SliTaz package receipt. |
pascal@15723 | 2 |
pascal@15723 | 3 PACKAGE="tmux-mem-cpu-load" |
Hans-G?nter@22045 | 4 VERSION="3.4.0" |
pascal@15723 | 5 CATEGORY="utilities" |
Hans-G?nter@22045 | 6 SHORT_DESC="CPU, RAM, and load monitor for use with tmux." |
pascal@15723 | 7 MAINTAINER="paul@slitaz.org" |
pascal@15723 | 8 LICENSE="Apache" |
pascal@20679 | 9 WEB_SITE="https://github.com/tmux/tmux/wiki" |
Hans-G?nter@22045 | 10 |
Hans-G?nter@22045 | 11 TARBALL="$PACKAGE-$VERSION.tar.gz" |
Hans-G?nter@22045 | 12 WGET_URL="https://github.com/thewtex/$PACKAGE/archive/v$VERSION.tar.gz" |
pascal@15723 | 13 |
pascal@15723 | 14 DEPENDS="tmux" |
Hans-G?nter@22045 | 15 BUILD_DEPENDS="cmake python" |
pascal@15723 | 16 |
pascal@24055 | 17 current_version() |
pascal@24055 | 18 { |
pascal@24055 | 19 wget -O - ${WGET_URL%/arch*}/releases 2>/dev/null | \ |
pascal@24055 | 20 sed '/archive.*tar/!d;s|.*/v\(.*\).tar.*|\1|;q' |
pascal@24055 | 21 } |
pascal@24055 | 22 |
pascal@15723 | 23 # Rules to configure and make the package. |
pascal@15723 | 24 compile_rules() |
pascal@15723 | 25 { |
pascal@15723 | 26 cmake . -DCMAKE_INSTALL_PREFIX=/usr |
Hans-G?nter@22045 | 27 make && |
Hans-G?nter@22045 | 28 make install |
pascal@15723 | 29 } |
pascal@15723 | 30 |
pascal@15723 | 31 # Rules to gen a SliTaz package suitable for Tazpkg. |
pascal@15723 | 32 genpkg_rules() |
pascal@15723 | 33 { |
Hans-G?nter@22045 | 34 mkdir -p $fs/usr |
Hans-G?nter@22045 | 35 mkdir -p $fs/etc/skel |
Hans-G?nter@22045 | 36 |
pascal@15723 | 37 cp -a $install/usr/bin $fs/usr |
pascal@17085 | 38 cat >> $fs/etc/skel/.tmux.conf << EOT |
pascal@17085 | 39 # tmux-mem-cpu-load |
pascal@17085 | 40 set -g status-interval 2 |
pascal@17085 | 41 set -g status-right "#[fg=black,bg=green]#(tmux-mem-cpu-load 2)#[default]" |
pascal@17085 | 42 EOT |
pascal@15723 | 43 } |
pascal@15723 | 44 |
pascal@15723 | 45 post_install() |
pascal@15723 | 46 { |
Hans-G?nter@22045 | 47 for i in $(ls "$1/home" 2> /dev/null) |
Hans-G?nter@22045 | 48 do |
pascal@18732 | 49 grep -qs "tmux-mem-cpu-load" "$1/home/$i/.tmux.conf" && continue |
pascal@17085 | 50 echo -n "Checking for .tmux.conf for $i ..." |
pascal@18732 | 51 cp -a "$1/etc/skel/.tmux.conf" "$1/home/$i/" |
pascal@18730 | 52 chroot "$1/" chown $(stat -c "%u.%g" "$1/home/$i") "/home/$i/.tmux.conf" |
pascal@17085 | 53 status |
Hans-G?nter@22045 | 54 done |
pascal@15723 | 55 } |