Add support for DEBUG flag

This commit is contained in:
David Coppit
2015-06-27 13:30:15 -04:00
parent 33c19314b3
commit 99f51ecc05
2 changed files with 8 additions and 3 deletions

View File

@@ -202,12 +202,14 @@ while true
do
if read RECORD
then
if [[ "$DEBUG" == "1" ]]
then
echo "$(ts) [DEBUG] $RECORD"
fi
EVENT=$(echo "$RECORD" | cut -d' ' -f 1)
FILE=$(echo "$RECORD" | cut -d' ' -f 2-)
# echo "EVENT=$EVENT"
# echo "FILE=$FILE"
if ! is_change_event "$EVENT" "$FILE"
then
continue