summaryrefslogtreecommitdiff
path: root/compare.sh
diff options
context:
space:
mode:
authorF3RR3T <github@st33v.com>2014-09-06 22:04:16 +1000
committerF3RR3T <github@st33v.com>2014-09-06 22:04:16 +1000
commite779a2afe559d67bef12bb57f1a4ce0de06b9c81 (patch)
treee75ae52ce5eb8019227ae5ab2b9d20c81fbb44bf /compare.sh
parente90ead311dff1bccd50cbea8e2e915c185537e53 (diff)
Monitor now ckecks for IP change and invokes email notification
Diffstat (limited to 'compare.sh')
-rwxr-xr-xcompare.sh3
1 files changed, 2 insertions, 1 deletions
diff --git a/compare.sh b/compare.sh
index 1db6a21..7d0dc4c 100755
--- a/compare.sh
+++ b/compare.sh
@@ -13,6 +13,7 @@ else
fi
+# read a whole file line by line
#i=0
#while read line
#do
@@ -35,4 +36,4 @@ lastip=$(echo $lastline | awk '{ print $2 }')
echo "Last = $lastip"
-[ "$lastip" = "$firstip" ] && echo 'match' || echo 'different'
+[ "$lastip" == "$firstip" ] && echo 'match' || echo 'different'