Hello Don Cragun !
Thanks to show me the right way to insert code in my post and thanks for the reply,
Now with your help I don't have errors in the script but the result is wrong.
I check the two checksums are the same and the sh script give it changes.
I cannot give the url now because I need 5 posts but i can send you a capture.
---------- Post updated at 11:30 AM ---------- Previous update was at 11:24 AM ----------
OK I found my error
---------- Post updated at 11:31 AM ---------- Previous update was at 11:30 AM ----------
there is a " -"
after the second checksum the just verified now one.
---------- Post updated at 11:33 AM ---------- Previous update was at 11:31 AM ----------
I added th space and the "-" but I now have an error
~# sh verif2.sh
verif2.sh: 3: verif2.sh: -: not found
I'm trying different with quotes etc.
---------- Post updated at 11:37 AM ---------- Previous update was at 11:33 AM ----------
Hello again, now i don't understand because it still give the "change" result and I checked with an echo to see the two different results and they are the same !
if [ "$last_checksum" = "$checksum" ]
then
echo "rien"
else
echo "change"
fi
echo $last_checksum
echo $checksum
it gives :
sh verif2.sh
change
52f8422918c5347166dbb40c76f95e9c -
52f8422918c5347166dbb40c76f95e9c -
we see it's the same it say "change" is there a reason for this ?
---------- Post updated at 11:47 AM ---------- Previous update was at 11:37 AM ----------
Sorry again, I find out !
with the quotes, the new checksum echo result is different thant without the quotes : one more space " -"
If i delete the quote at the first declaration of the checksum valeur its give an operator error, so i add one more space in my last checksum and it works ! !
Thank you so much for your super clear explanations !
I'm now trying to insert it in a cron and send me an email if it changes, the vps where I run this script already works for sending emails because my logwatch emails are finely received.
thank you again.
when I was a kid computers were my hobby and when I can afford it and when my usage of computers fit some of my needs I'm happy to do it myself. But I can confess actually I m jobless in japan and need money so this time I'm not defendable to spend so much time in this hobby...
I really apreciate your help !
Thank you.