ditto
This commit is contained in:
parent
d17db8aa20
commit
0f8036657b
|
@ -2166,7 +2166,7 @@ function checkfor() { # checkfor name [pkg_name]
|
|||
pkg_name=${2:-$what}
|
||||
os=$(uname -s)
|
||||
hw=$(uname -m)
|
||||
if [[ $hw == "aarch64" ]]; then # Android Termuz
|
||||
if [[ $hw == "aarch64" ]]; then # Android Termux
|
||||
alias which="command -v"
|
||||
fi
|
||||
which $what >/dev/null 2>&1
|
||||
|
@ -2207,10 +2207,14 @@ function checkfor() { # checkfor name [pkg_name]
|
|||
apt-get install $pkg_name && ok=1
|
||||
elif [[ -f /etc/redhat_release ]]; then
|
||||
apt-get install $pkg_name && ok=1
|
||||
elif [[ $hw == "aarch64" ]]; then
|
||||
apt install $pkg_name && ok=1
|
||||
else
|
||||
error "Don't know how to install stuff on OS '$os' HW '$hw'"
|
||||
fi
|
||||
;;
|
||||
*)
|
||||
echo "Don't know how to install stuff on OS '$os'"
|
||||
error "Don't know how to install stuff on OS '$os' HW '$hw'"
|
||||
;;
|
||||
esac
|
||||
[[ $ok -eq 1 ]] && info "Successfully installed $pkg_name" || error "Failed to install $pkg_name"
|
||||
|
@ -2455,6 +2459,7 @@ fi
|
|||
|
||||
checkfor gdate coreutils || exit 1
|
||||
checkfor jq || exit 1
|
||||
checkfor gsed || exit 1
|
||||
|
||||
loadservers
|
||||
if [[ $nlocs -lt 1 ]]; then
|
||||
|
|
Loading…
Reference in New Issue