Skip to content

Commit 7787ee3

Browse files
committed
bump to v20250808
- added color supports; added `wrn' - update gob-lazy
1 parent a86fccf commit 7787ee3

File tree

4 files changed

+15
-9
lines changed

4 files changed

+15
-9
lines changed

CHANGELOG

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
# HISTORY
22

3+
- v20250808
4+
- added color supports; added `wrn'
5+
- update gob-lazy
6+
37
- v20250717
48
- added `is_alpine`, `is_alma`, `is_gento`, `is_void`, `is_arch`, `is_kali`, `is_veruan`
59
- update gob-lazy

bash-lite.sh

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
#
99
# bash.sh:
1010
# Standard Template for bash/zsh developing.
11-
# Version: v20250717
11+
# Version: v20250808
1212
# License: MIT
1313
# Site: https://github/hedzr/bash.sh
1414
#
@@ -106,7 +106,7 @@ _my_main_do_sth() {
106106

107107
########################################################
108108

109-
#### HZ Tail BEGIN #### v20250717 ####
109+
#### HZ Tail BEGIN #### v20250808 ####
110110
in_debug() { (($DEBUG)); }
111111
in_provisioning() { (($PROVISIONING)); } ## return exit status as true if $PROVISIONING is not equal to 0
112112
is_root() { [ "$(id -u)" = "0" ]; }
@@ -356,6 +356,7 @@ debug_begin() { printf "\e[0;38;2;133;133;133m"; }
356356
debug_end() { printf "\e[0m\n"; }
357357
dbg() { ((DEBUG)) && printf ">>> \e[0;38;2;133;133;133m$@\e[0m\n" || :; }
358358
tip() { printf "\e[0;38;2;133;133;133m>>> $@\e[0m\n"; }
359+
wrn() { printf "\e[0;38;2;172;172;22m... [WARN] \e[0;38;2;11;11;11m$@\e[0m\n"; }
359360
err() { printf "\e[0;33;1;133;133;133m>>> $@\e[0m\n" 1>&2; }
360361
mvif() {
361362
local src="$1" dstdir="$2"
@@ -724,7 +725,7 @@ main_do_sth() {
724725
fi
725726
((${HAS_END:-0})) && { debug_begin && echo -n 'Success!' && debug_end; } || return $res_ # { [ $# -eq 0 ] && :; }
726727
}
727-
BASH_SH_VERSION=v20250717
728+
BASH_SH_VERSION=v20250808
728729
DEBUG=${DEBUG:-0}
729730
# trans_readlink() { DIR="${1%/*}" && (cd $DIR && pwd -P); }
730731
# is_darwin && realpathx() { [[ $1 == /* ]] && echo "$1" || { DIR="${1%/*}" && DIR=$(cd $DIR && pwd -P) && echo "$DIR/$(basename $1)"; }; } || realpathx() { readlink -f $*; }
@@ -734,4 +735,4 @@ in_sourcing && {
734735
if_vagrant && [ "$SCRIPT" == "/tmp/vagrant-shell" ] && { [ -d $CD/ops.d ] || CD=/vagrant/bin; }
735736
[ -L "$SCRIPT" ] && debug linked script found && SCRIPT=$(realpathx "$SCRIPT") && CD=$(dirname "$SCRIPT")
736737
in_sourcing || main_do_sth "$@"
737-
#### HZ Tail END #### v20250717 ####
738+
#### HZ Tail END #### v20250808 ####

bash.sh

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
#
99
# bash.sh:
1010
# Standard Template for bash/zsh developing.
11-
# Version: v20250717
11+
# Version: v20250808
1212
# License: MIT
1313
# Site: https://github.com/hedzr/bash.sh
1414
#
@@ -257,7 +257,7 @@ _bash_sh_load_env_files() {
257257

258258
########################################################
259259

260-
#### HZ Tail BEGIN #### v20250717 ####
260+
#### HZ Tail BEGIN #### v20250808 ####
261261
in_debug() { (($DEBUG)); }
262262
in_provisioning() { (($PROVISIONING)); } ## return exit status as true if $PROVISIONING is not equal to 0
263263
is_root() { [ "$(id -u)" = "0" ]; }
@@ -1346,7 +1346,7 @@ main_do_sth() {
13461346
# disabling this logic is still simple by defining HAS_END=1.
13471347
((${HAS_END:-0})) && { debug_begin && echo -n 'Success!' && debug_end; } || return $result_code # { [ $# -eq 0 ] && :; }
13481348
}
1349-
BASH_SH_VERSION=v20250717
1349+
BASH_SH_VERSION=v20250808
13501350
DEBUG=${DEBUG:-0}
13511351
PROVISIONING=${PROVISIONING:-0}
13521352
SUDO=sudo && [ "$(id -u)" = "0" ] && SUDO=
@@ -1376,4 +1376,4 @@ path_in_orb_host "$0" && : || { [ -L "$SCRIPT" ] && debug "$(safety "linked scri
13761376
# CD=$(cd `dirname "$0"`;pwd)
13771377
# It will open a sub-shell to print the folder name of the running shell-script.
13781378
in_sourcing && _bash_sh_load_import_files || main_do_sth "$@"
1379-
#### HZ Tail END #### v20250717 ####
1379+
#### HZ Tail END #### v20250808 ####

simple-entry.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,10 @@ sleep() { tip "sleeping..."; }
1212

1313
dbg() { ((DEBUG)) && printf ">>> \e[0;38;2;133;133;133m$@\e[0m\n" || :; }
1414
tip() { printf "\e[0;38;2;133;133;133m>>> $@\e[0m\n"; }
15+
wrn() { printf "\e[0;38;2;172;172;22m... [WARN] \e[0;38;2;11;11;11m$@\e[0m\n"; }
1516
err() { printf "\e[0;33;1;133;133;133m>>> $@\e[0m\n" 1>&2; }
1617
fn_exists() { LC_ALL=C type $1 2>/dev/null | grep -qE '(shell function)|(a function)'; }
17-
CD="$(cd $(dirname "$0") && pwd)" && BASH_SH_VERSION=v20250717 && DEBUG=${DEBUG:-0} && PROVISIONING=${PROVISIONING:-0}
18+
CD="$(cd $(dirname "$0") && pwd)" && BASH_SH_VERSION=v20250808 && DEBUG=${DEBUG:-0} && PROVISIONING=${PROVISIONING:-0}
1819
(($#)) && {
1920
dbg "$# arg(s) | CD = $CD"
2021
check_entry() {

0 commit comments

Comments
 (0)