elvish_config/aliases/meteo.elv

11 lines
256 B
Plaintext

edit:add-var meteo~ {|@argv|
use str
var city = 'Montbéliard'
if (> (count $argv) 0) {
set city = (str:join '' $argv)
}
var url = (printf 'wttr.in/%s?lang=fr' $city)
#curl --connect-timeout 2 $url
e:curlie -s --connect-timeout 2 $url
}