style(helpers): reformat helper script
This commit is contained in:
parent
bc2a34ddd8
commit
e208d22664
@ -51,8 +51,9 @@ checkExist() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
scriptHelp() {
|
scriptHelp() {
|
||||||
printf "\n%s%1000s\n" "$magenta" | tr " " "-" | cut -c -$width
|
printf "\n%s" "$magenta"
|
||||||
printf "%s" "$norm"
|
printf '%.0s-' $(seq "$width")
|
||||||
|
printf "\n%s" "$norm"
|
||||||
textblock "This is a simple helper script so you can avoid typing lengthy commands when working with the ab-nginx container."
|
textblock "This is a simple helper script so you can avoid typing lengthy commands when working with the ab-nginx container."
|
||||||
textblock "The script reads the contents of 'ab-nginx.params' and constructs various 'docker run' commands based on that file. The biggest time-saver is working with certificates. If they are specified in the params file, the script will automatically bind-mount them so nginx serves content via SSL by default."
|
textblock "The script reads the contents of 'ab-nginx.params' and constructs various 'docker run' commands based on that file. The biggest time-saver is working with certificates. If they are specified in the params file, the script will automatically bind-mount them so nginx serves content via SSL by default."
|
||||||
newline
|
newline
|
||||||
@ -71,7 +72,9 @@ scriptHelp() {
|
|||||||
printf "%s" "$yellow"
|
printf "%s" "$yellow"
|
||||||
newline
|
newline
|
||||||
textblock "More information can be found at: https://git.asifbacchus.dev/ab-docker/ab-nginx/wiki"
|
textblock "More information can be found at: https://git.asifbacchus.dev/ab-docker/ab-nginx/wiki"
|
||||||
printf "%s%1000s\n" "$magenta" | tr " " "-" | cut -c -$width
|
printf "\n%s" "$magenta"
|
||||||
|
printf '%.0s-' $(seq "$width")
|
||||||
|
printf "\n%s" "$norm"
|
||||||
exit 0
|
exit 0
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -96,7 +99,7 @@ textblockParam() {
|
|||||||
### pre-requisite checks
|
### pre-requisite checks
|
||||||
|
|
||||||
# is docker installed?
|
# is docker installed?
|
||||||
if ! command -v docker > /dev/null; then
|
if ! command -v docker >/dev/null; then
|
||||||
printf "%s\nCannot find docker... is it installed?\n%s" "$err" "$norm"
|
printf "%s\nCannot find docker... is it installed?\n%s" "$err" "$norm"
|
||||||
exit 2
|
exit 2
|
||||||
fi
|
fi
|
||||||
|
Loading…
Reference in New Issue
Block a user