owa 0.1.0 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 88d8bef6dd5b6f2fb71e2f3d9612cfa754afb477
4
- data.tar.gz: 3b7bc6cf50a4fe6b95fefdfcc34cb898dfdb860e
3
+ metadata.gz: ac111070916de4edc9eae40da0ff07c5c9c833c8
4
+ data.tar.gz: 7fee60ac345ac8a1be96802c6969757b47474459
5
5
  SHA512:
6
- metadata.gz: 91c6ab8e5a44f906e35da676d2fbd96632e5ae19eb51b335f733d4d097b86ad04b917ec8ce6cd827d2d09ac2808ebf7900697b1c795070a0809520eced330702
7
- data.tar.gz: 8bb18bbe9e623a7df4e2d69d4c9d8656024ae478075ca9f2f8dd84daa9c9cb7fd4f04686e04ae28cef98597c22a5a31f8a035b2700cb60fa0b3780b9a273b36d
6
+ metadata.gz: '00940056c6478b58b941491a3b8c6d25c288f451ec5275c413a641b72eeb6d15dee1f5dd0bdc66b0a26d1c9a548b8f36d8d8e72cea4d1b408dcc9094c0f814fe'
7
+ data.tar.gz: 827142b6f21b1edadfec3e4763e2ca028a1ea64b54103c41739045a3b111f93d66c7ba3678b18d104bfcf0f3a3929c1630141068029aaaa1fb012d59673c7874
data/README.md CHANGED
@@ -19,10 +19,11 @@ Or install it yourself as:
19
19
 
20
20
  You will need to initialize it after installation. If you are using this gem in a Rails application you can add the initialization in your `config/initializers/owa.rb`:
21
21
 
22
- ``` ruby
22
+ ```ruby
23
23
  Owa.configure do |config|
24
- config.api_url="https://api.openweathermap.org/data/2.5"
25
- config.appid="your_appid_from_owm_api"
24
+ config.api_url = "https://api.openweathermap.org/data/2.5"
25
+ config.appid = "your_appid_from_owm_api"
26
+ config.units = "metric"
26
27
  end
27
28
  ```
28
29
 
@@ -32,7 +33,7 @@ At this moment there are only two ways to use this client(more to be implemented
32
33
 
33
34
  - To get a weather by a City and Countrycode. CountryCode can be used optionally.
34
35
 
35
- ```
36
+ ```ruby
36
37
  Owa::Current.by_city("berlin", "DE")
37
38
  # Or
38
39
  Owa::Current.by_city("berlin")
@@ -40,7 +41,7 @@ Owa::Current.by_city("berlin")
40
41
 
41
42
  - To get the weather by geocode.
42
43
 
43
- ```
44
+ ```ruby
44
45
  Owa::Current.by_geocode("130", "80")
45
46
  ```
46
47
 
@@ -1,5 +1,5 @@
1
1
  module Owa
2
2
  class Configuration
3
- attr_accessor :api_url, :appid
3
+ attr_accessor :api_url, :appid, :units
4
4
  end
5
5
  end
@@ -14,7 +14,8 @@ module Owa
14
14
  private
15
15
 
16
16
  def default_params
17
- { appid: Owa::configuration.appid }
17
+ { appid: Owa::configuration.appid,
18
+ units: Owa::configuration.units }
18
19
  end
19
20
  end
20
21
  end
@@ -1,3 +1,3 @@
1
1
  module Owa
2
- VERSION = "0.1.0"
2
+ VERSION = "0.1.1"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: owa
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - hosseintoussi
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-10-15 00:00:00.000000000 Z
11
+ date: 2017-10-16 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler