weather_jp 0.0.5 → 0.0.6

Sign up to get free protection for your applications and to get access to all the features.
data/README.md CHANGED
@@ -6,6 +6,8 @@ Fetch Japan weather info as Ruby object easily.
6
6
 
7
7
  http://taiki45.github.com/weather_jp
8
8
 
9
+ https://rubygems.org/gems/weather_jp
10
+
9
11
  ## Installation
10
12
 
11
13
  Add this line to your application's Gemfile:
@@ -24,18 +26,18 @@ Or install it yourself as:
24
26
 
25
27
  ```ruby
26
28
  # creat weather object in differrnt ways
27
- tokyo = WeatherJP::Weather.new :tokyo
29
+ tokyo = WeatherJp::Weather.new :tokyo
28
30
  minato = WeatherJp::Weather.new("東京都港区")
29
31
 
30
32
  # get weather info as String
31
- tokyo.get_weather(:today).to_s
33
+ tokyo.today.to_s
32
34
  #=> can be "東京都 東京の天気は曇りのち晴れ、最高気温34度...etc"
33
35
 
34
36
  # to get weather info in differrnt ways
35
37
  minato.get_weather(4) #=> <#DayWeather object>
36
- minato.get_weather(:today).forecast #=> can be "晴れ"
37
- tokyo.today
38
- minato.day_after_tomorrow
38
+ minato.today.forecast #=> can be "晴れ"
39
+ tokyo.get_weather(:tomorrow).rain
40
+ minato.day_after_tomorrow.to_s
39
41
 
40
42
  # use Weather object
41
43
  tokyo.each do |w|
@@ -53,6 +55,14 @@ minato.each {|w| p w.to_hash }
53
55
 
54
56
  ```
55
57
 
58
+ ## Requires
59
+
60
+ Ruby >= 1.9.2
61
+
62
+ ## Documents
63
+
64
+ http://rubydoc.info/gems/weather_jp/0.0.5/frames
65
+
56
66
  ## Contributing
57
67
 
58
68
  1. Fork it
@@ -60,3 +70,8 @@ minato.each {|w| p w.to_hash }
60
70
  3. Commit your changes (`git commit -am 'Added some feature'`)
61
71
  4. Push to the branch (`git push origin my-new-feature`)
62
72
  5. Create new Pull Request
73
+
74
+ Feel free to any requests or bug reports, issues, comments.
75
+
76
+ Thank you :)
77
+
data/Rakefile CHANGED
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env rake
2
- require "bundler/gem_tasks"
3
2
  require "bundler"
4
-
3
+ Bundler::GemHelper.install_tasks
4
+ #
5
5
  begin
6
6
  Bundler.setup(:default, :development)
7
7
  rescue Bundler::BundlerError => e
@@ -10,9 +10,10 @@ rescue Bundler::BundlerError => e
10
10
  exit e.status_code
11
11
  end
12
12
 
13
- require "rspec/core"
14
13
  require "rspec/core/rake_task"
15
-
16
- RSpec::Core::RakeTask.new(:spec)
14
+ RSpec::Core::RakeTask.new(:spec) do |task|
15
+ task.rspec_opts = ["-c", "-fs"]
16
+ end
17
17
 
18
18
  task :default => :spec
19
+ task :test => :spec
@@ -27,7 +27,8 @@ module WeatherJp
27
27
  def inspect
28
28
  word = "\#<DayWeather:@city_name = #{city_name}, "
29
29
  word << "@day=#{day}, @forecast=#{forecast}, "
30
- word << "@max_temp=#{max_temp}, @rain=#{rain}>"
30
+ word << "@max_temp=#{max_temp}, @min_temp=#{min_temp}, "
31
+ word << "@rain=#{rain}>"
31
32
  word
32
33
  end
33
34
 
@@ -1,3 +1,3 @@
1
1
  module WeatherJp
2
- VERSION = "0.0.5"
2
+ VERSION = "0.0.6"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: weather_jp
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.5
4
+ version: 0.0.6
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-08-02 00:00:00.000000000 Z
12
+ date: 2012-08-03 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: nokogiri
@@ -109,7 +109,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
109
109
  version: '0'
110
110
  segments:
111
111
  - 0
112
- hash: -3783802074571273294
112
+ hash: 1270333121761837627
113
113
  required_rubygems_version: !ruby/object:Gem::Requirement
114
114
  none: false
115
115
  requirements:
@@ -118,7 +118,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
118
118
  version: '0'
119
119
  segments:
120
120
  - 0
121
- hash: -3783802074571273294
121
+ hash: 1270333121761837627
122
122
  requirements: []
123
123
  rubyforge_project:
124
124
  rubygems_version: 1.8.23