comparison db/getwunderday @ 0:9dab44dcb331

Initial commit of Greg's code from http://www.lemis.com/grog/tmp/wh1080.tar.gz
author Daniel O'Connor <darius@dons.net.au>
date Tue, 09 Feb 2010 13:44:25 +1030
parents
children
comparison
equal deleted inserted replaced
-1:000000000000 0:9dab44dcb331
1 #!/bin/sh
2 # $Id: getwunderday,v 1.1 2009/12/08 23:32:32 grog Exp $
3 #
4 # Get CSV data from Wunderground.
5 #
6 if [ $# -ne 5 ]; then
7 echo Usage: $0 day month year station dest
8 exit 1
9 fi
10 DAY=$1
11 MONTH=$2
12 YEAR=$3
13 STATION=$4
14 DEST=$5
15 fetch -o $DEST http://www.wunderground.com/weatherstation/WXDailyHistory.asp?ID=$STATION\&month=$MONTH\&day=$DAY\&year=$YEAR\&format=1
16 insertwunderground < $DEST $STATION | mysql weather