mirror of
https://github.com/octoleo/telegram-bot-bash.git
synced 2024-11-22 15:35:09 +00:00
Added shellcheck source for background script examples
This commit is contained in:
parent
676a69465d
commit
d64ba40b63
@ -24,6 +24,7 @@ unset IFS
|
||||
# discard STDIN for background jobs!
|
||||
cat >/dev/null &
|
||||
|
||||
# shellcheck source=examples/background-scripts/mycommands.sh
|
||||
source "./mycommands.sh"
|
||||
|
||||
# check if $1 is a number
|
||||
|
@ -24,6 +24,8 @@ cat >/dev/null &
|
||||
|
||||
# watch for new files created by a trusted program
|
||||
WATCHDIR="/my_trusted/dir_to_watch"
|
||||
|
||||
# shellcheck source=examples/background-scripts/mycommands.sh
|
||||
source "./mycommands.sh"
|
||||
|
||||
# test your script and the remove ...
|
||||
@ -39,4 +41,3 @@ loop_callback() {
|
||||
}
|
||||
|
||||
watch_dir_loop "$WATCHDIR"
|
||||
|
||||
|
@ -19,11 +19,13 @@ export 'LANGUAGE=C.UTF-8'
|
||||
unset IFS
|
||||
# set -f # if you are paranoid use set -f to disable globbing
|
||||
|
||||
# discard STDIN for background jobs!
|
||||
# shellcheck source=examples/background-scripts/mycommands.sh
|
||||
cat >/dev/null &
|
||||
|
||||
# watch for new logfiles
|
||||
WATCHDIR="/var/log"
|
||||
|
||||
# shellcheck disable=SC1091
|
||||
source "./mycommands.sh"
|
||||
|
||||
# test your script and the remove ...
|
||||
|
Loading…
Reference in New Issue
Block a user