Last active
September 6, 2015 05:10
-
-
Save rjhornsby/1a672c22a0b7f081dd28 to your computer and use it in GitHub Desktop.
Output the GFNB temperature readings
This file contains hidden or 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 | |
# Set this to your router's address # | |
gfnb_ip=192.168.2.1 | |
# Don't change anything below this line # | |
echo -n "$(date) " | |
curl -s "http://$gfnb_ip/content.json?checksum=0&_=0" | ruby -rjson -e 'puts JSON.parse(STDIN.read)["temperature"]' | |
exit 0 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment