jake-scripts 1.9.1 → 1.9.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/exe/weather +5 -5
- data/lib/jake/scripts/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 37a71657349e68631062e1de70b9f5ceb5eb3977
|
4
|
+
data.tar.gz: 315902773074bbf31a417b3a4e1064f1f3b339a7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2a869a79305f0e3eb18718bd174641e90458bf292135a9f400e83473d5a20eb1ec443eb331fdbb83c9de32e304e47062c9a07131e99f4c97b8ca823d157ae961
|
7
|
+
data.tar.gz: 82c140e1496da4e9515ade0435745d332c648e8f791a2bbf4d6575fdbd8add8471decf92514efa87dd942255b896f8b5ffe2594097df76ca04345bf11a3026f7
|
data/exe/weather
CHANGED
@@ -13,7 +13,7 @@ def weather_search
|
|
13
13
|
url = "http://ip-api.com/json"
|
14
14
|
response = RestClient.get(url)
|
15
15
|
parsed = JSON.parse(response)
|
16
|
-
location = parsed["city"]
|
16
|
+
location = ARGV || parsed["city"]
|
17
17
|
rescue
|
18
18
|
puts "No IP Address"
|
19
19
|
exit(1)
|
@@ -33,7 +33,7 @@ def weather_search
|
|
33
33
|
wind_speed = parsed["current"]["wind_mph"]
|
34
34
|
humidity = parsed["current"]["humidity"]
|
35
35
|
feels_like = parsed["current"]["feelslike_f"]
|
36
|
-
|
36
|
+
visibility = parsed["current"]["vis_miles"]
|
37
37
|
|
38
38
|
# Output for United States
|
39
39
|
puts
|
@@ -43,7 +43,7 @@ def weather_search
|
|
43
43
|
puts "| Feels Like: #{feels_like}°F"
|
44
44
|
puts "| Humidity: #{humidity}%"
|
45
45
|
puts "| Wind Speed: #{wind_speed} mph"
|
46
|
-
puts "|
|
46
|
+
puts "| Visibility: #{visibility} mi"
|
47
47
|
puts "======================"
|
48
48
|
puts
|
49
49
|
else
|
@@ -53,7 +53,7 @@ def weather_search
|
|
53
53
|
wind_speed = parsed["current"]["wind_kph"]
|
54
54
|
humidity = parsed["current"]["humidity"]
|
55
55
|
feels_like = parsed["current"]["feelslike_c"]
|
56
|
-
|
56
|
+
visibility = parsed["current"]["vis_km"]
|
57
57
|
|
58
58
|
# Output for Metric countries
|
59
59
|
puts
|
@@ -63,7 +63,7 @@ def weather_search
|
|
63
63
|
puts "| Feels Like: #{feels_like}°C"
|
64
64
|
puts "| Humidity: #{humidity}%"
|
65
65
|
puts "| Wind Speed: #{wind_speed} kph"
|
66
|
-
puts "|
|
66
|
+
puts "| Visibility: #{visibility} km"
|
67
67
|
puts "======================"
|
68
68
|
puts
|
69
69
|
end
|
data/lib/jake/scripts/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: jake-scripts
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.9.
|
4
|
+
version: 1.9.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jake Meyer
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-06-
|
11
|
+
date: 2017-06-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|