From c835e0516cc327aec678a7e78969d0b1a34b0c46 Mon Sep 17 00:00:00 2001 From: "Kay Marquardt (Gnadelwartz)" Date: Fri, 26 Apr 2019 11:41:25 +0200 Subject: [PATCH] more failsave module sourcing --- bashbot.sh | 2 +- commands.sh | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/bashbot.sh b/bashbot.sh index e8fa6e3..0595b9f 100755 --- a/bashbot.sh +++ b/bashbot.sh @@ -12,7 +12,7 @@ # This file is public domain in the USA and all free countries. # Elsewhere, consider it to be WTFPLv2. (wtfpl.net/txt/copying) # -#### $$VERSION$$ v0.70-dev3-8-gb8a23c4 +#### $$VERSION$$ v0.70-dev3-10-g81c8b04 # # Exit Codes: # - 0 sucess (hopefully) diff --git a/commands.sh b/commands.sh index 44bb2a0..a13a9d4 100644 --- a/commands.sh +++ b/commands.sh @@ -5,7 +5,7 @@ # This file is public domain in the USA and all free countries. # Elsewhere, consider it to be WTFPLv2. (wtfpl.net/txt/copying) # -#### $$VERSION$$ v0.70-dev3-8-gb8a23c4 +#### $$VERSION$$ v0.70-dev3-10-g81c8b04 # # shellcheck disable=SC2154 # shellcheck disable=SC2034 @@ -42,9 +42,9 @@ Get the code in my [GitHub](http://github.com/topkecleon/telegram-bot-bash) # load modules # shellcheck source=./modules/aliases.sh - [ -r "${MODULEDIR}/aliases.sh" ] && source "${MODULEDIR}/aliases.sh" + [ -r "${MODULEDIR:-.}/aliases.sh" ] && source "${MODULEDIR:-.}/aliases.sh" # shellcheck source=./modules/background.sh - [ -r "${MODULEDIR}/background.sh" ] && source "${MODULEDIR}/background.sh" + [ -r "${MODULEDIR:-.}/background.sh" ] && source "${MODULEDIR:-.}/background.sh" # ... more modules here ... # mycommands is the last "module" to source in