Created
June 7, 2018 15:33
-
-
Save jamesona/e6c2228c0a696fb45e365bfe64af8c2a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
FILE=$1 | |
if [ -f $FILE ]; then | |
curl $FILE > $FILE.new | |
cmp --silent $FILE $FILE.new || <do stuff here because the website changed> | |
else | |
curl $FILE > $file | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment