Mercurial > ~darius > hgwebdir.cgi > wh1080
view wundersend @ 3:dc5ff2a1ed81
Be smarter about retries.
If the interrupt endpoint can't be read 100 times then retry the whole request.
author | Daniel O'Connor <darius@dons.net.au> |
---|---|
date | Wed, 10 Feb 2010 11:33:27 +1030 |
parents | 9dab44dcb331 |
children |
line wrap: on
line source
#!/bin/sh # $Id: wundersend,v 1.1 2009/11/22 23:33:06 grog Exp $ # Send a report to Wunderground and log if it fails RESULTFILE=/var/tmp/wunderground.$$ fetch -o $RESULTFILE $1 RESULT=`cat $RESULTFILE` if [ "$RESULT" != "success" ]; then logger "wh1080: Can't send update to Wunderground: $RESULT" fi rm $RESULTFILE