Adding interactivity for all scripts, running all scripts in 1 ssh session.

This commit is contained in:
Adsooi 2022-05-07 23:02:40 +02:00
parent 20b789268f
commit fdc09b75f7
Signed by: Ad5001
GPG key ID: EF45F9C6AFE20160
2 changed files with 34 additions and 10 deletions

View file

@ -36,6 +36,8 @@ RESET_INVERT="\e[27m"
GRAY_FG="\e[90m"
# Sets the forground color to green.
GREEN_FG="\e[92m"
# Sets the forground color to yellow
YELLOW_FG="\e[38;5;220m"
# Sets the forground color to blue.
BLUE_FG="\e[94m"
@ -51,7 +53,7 @@ BLACK_FG="\e[30m"
# Sets the forground color to light green.
L_GREEN_FG="\e[32m"
# Sets the forground color to orange.
ORANGE_FG="\e[33m"
ORANGE_FG="\e[38;5;166m" #"\e[33m"
# Sets the forground color to red.
RED_FG="\e[38;5;204m"
@ -60,7 +62,7 @@ BLACK_BG="\e[40m"
# Sets the background color to light green.
L_GREEN_BG="\e[42m"
# Sets the background color to orange.
ORANGE_BG="\e[43m"
ORANGE_BG="\e[48;5;166m"
# Sets the background color to red.
RED_FG="\e[48;5;204m"
@ -68,8 +70,10 @@ RED_FG="\e[48;5;204m"
# Signature: (<string command>) -> string
run_as_root() {
echo "$PASSWORD" | sudo -p "" -i -S bash -c "$@"
#sudo bash -c "$@"
}
# Simple info blue command.
# Signature: (<string message>) -> string
info() {