comparison db/getremote-today @ 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: getremote-today,v 1.4 2010/01/02 03:01:02 grog Exp $
3 # Get today's readings
4 # Wunderground
5 WEATHERDIR=/home/`whoami`/household/weather
6 STATIONS="IVICTORI86 IVICTORI94 IVICTORI102 IVICTORI115 IVICMTHE3 IVICREDA2"
7 PATH=$PATH:/home/grog/src/weather/WH-1080:/home/grog/src/weather/WH-1080/db:/usr/local/bin
8 DAY=`date +%d`
9 MONTH=`date +%m`
10 YEAR=`date +%Y`
11 for STATION in $STATIONS; do
12 DESTDIR=$WEATHERDIR/wunderground/$STATION
13 mkdir -p $DESTDIR
14 getwunderday $DAY $MONTH $YEAR $STATION $DESTDIR/$YEAR-$MONTH-$DAY
15 done
16 # BoM
17 # Ballarat airport
18 fetch -o - http://www.bom.gov.au/fwo/IDV60801/IDV60801.94852.axf | insertBoM | mysql weather
19 # Melbourne airport
20 fetch -o - http://www.bom.gov.au/fwo/IDV60801/IDV60801.94866.axf | insertBoM | mysql weather
21 # Sheoaks
22 fetch -o - http://www.bom.gov.au/fwo/IDV60901/IDV60901.94863.axf | insertBoM | mysql weather
23 mysql < /home/grog/src/weather/WH-1080/db/tidy-observations
24 /home/grog/src/weather/WH-1080/plots/doplots