A Ruby library and CLI to get Japanese Weather via Livedoor Weather Web Service(http://weather.livedoor.com/weather_hacks/webservice).
Add this line to your application's Gemfile:
gem 'weather-report'
And then execute:
$ bundle
Or install it yourself as:
$ gem install weather-report
require 'weather-report'
# for easy use
tokyo = WeatherReport.get("東京")
tokyo.today.telop # => "晴れ"
# or you can write like this
id = WeatherReport::Weather.request_cityid("東京")
weather = WeatherReport::Weather.new(id)
weather.tomorrow.date # => <Date: 2013-05-04 ((2456417j,0s,0n),+0s,2299161j)>
weather.tomorrow.telop # => "雨"
weather.tomorrow.temperature_min # => 12
for more info, see http://rubydoc.info/gems/weather-report
- Fork it
- Create your feature branch (
git checkout -b my-new-feature
) - Commit your changes (
git commit -am 'Add some feature'
) - Push to the branch (
git push origin my-new-feature
) - Create new Pull Request