From e779a2afe559d67bef12bb57f1a4ce0de06b9c81 Mon Sep 17 00:00:00 2001 From: F3RR3T Date: Sat, 6 Sep 2014 22:04:16 +1000 Subject: Monitor now ckecks for IP change and invokes email notification --- compare.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'compare.sh') 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' -- cgit v1.3