POSIX compliance edit

master
Aaron Johnon 4 years ago
parent 505595b9f9
commit 101274c56b

@ -7,14 +7,14 @@ CONFIG=$1
### Provides KEY, CHATID, CHKLIST ### Provides KEY, CHATID, CHKLIST
if [ -n "$CONFIG" ]; then if [ -n "$CONFIG" ]; then
if [ -f "$CONFIG" ]; then if [ -f "$CONFIG" ]; then
source $CONFIG . $CONFIG #Source config file
else else
printf '%s\n' "$CONFIG: File does not exist." >&2 printf '%s\n' "$CONFIG: File does not exist." >&2
exit 10 exit 10
fi fi
else else
if [ -f ".httpcheck_telegram" ]; then if [ -f ".httpcheck_telegram" ]; then
source .httpcheck_telegram . .httpcheck_telegram #Source config file
else else
printf '%s\n' "No configuration file found." >&2 printf '%s\n' "No configuration file found." >&2
exit 10 exit 10

Loading…
Cancel
Save