some one asked this in the first few pages but i didnt see any answers...
Can anyone point me in the right direction of how to get weather status for Canadian cities and not american ones? thank you!
This should work (for Toronto)
Code:
curl --silent "http://xml.weather.yahoo.com/forecastrss?p=[COLOR="Orange"]CAXX0504[/COLOR]&u=[COLOR="RoyalBlue"]c[/COLOR]" | grep -E '(Current Conditions:|[COLOR="RoyalBlue"]C[/COLOR]<BR)' | sed -e 's/Current Conditions://' -e 's/<br \/>//' -e 's/<b>//' -e 's/<\/b>//' -e 's/<BR \/>//' -e 's/<description>//' -e 's/<\/description>//'
Replace text in orange for you city you want weather info on. (browser yahoo weather to the city you want and check it's code on the URL).
If you want Fahrenheit replace the 'c' in blue with 'f'.
Try it first in Terminal. If you get an error saying something about '<' then just escape this character in the command above.(i.e. replace '<' with '\<')
Hope it helps!
Edit: as you can see there's no difference between american cities, canadian cities or any other city around the world. (except for the city code!