kovid 0.4.8 → 0.4.9
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/lib/kovid/cli.rb +5 -1
- data/lib/kovid/tablelize.rb +1 -1
- data/lib/kovid/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: bc9b9acfefc8a4f38e6e02e51efec96a12b66be538f2f670d4277ee369ad504b
|
4
|
+
data.tar.gz: 8dca3b44e98ff6eb39015ada45ae8ba495a605091b3e851e6b435ebb090cf4ff
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b5cbc9a91bbd88538875e6c209008be0c4d47f9a786fe2df4d9c1ac06dc6f2070f0228802f939552792a10a1bf6b9703b78b7f4e4e173d373964d6bf6fef292b
|
7
|
+
data.tar.gz: d595e9cefcc3ff50b78cc8516ead8c9434fb1b3f7ab49570c83e3ba4016e3137c61bfe54131fa159276d0935d37f76ab3ea04e2ecb411c582b5d65b2f9b75b37
|
data/lib/kovid/cli.rb
CHANGED
@@ -6,6 +6,10 @@ require 'kovid'
|
|
6
6
|
module Kovid
|
7
7
|
class CLI < Thor
|
8
8
|
FULL_FLAG = %w[-f --full].freeze
|
9
|
+
|
10
|
+
def self.exit_on_failure?
|
11
|
+
true
|
12
|
+
end
|
9
13
|
|
10
14
|
desc 'check COUNTRY or check "COUNTRY NAME"', 'Returns reported data on provided country. eg: "kovid check "hong kong".'
|
11
15
|
method_option :full, aliases: '-f'
|
@@ -88,7 +92,7 @@ module Kovid
|
|
88
92
|
puts Kovid::VERSION
|
89
93
|
end
|
90
94
|
|
91
|
-
desc 'histogram', 'Returns a histogram of incidents.'
|
95
|
+
desc 'histogram COUNTRY M.YY', 'Returns a histogram of incidents.'
|
92
96
|
def histogram(country, date = nil)
|
93
97
|
if date.nil?
|
94
98
|
Kovid.info_table("Please add a month and year in the form 'M.YY'")
|
data/lib/kovid/tablelize.rb
CHANGED
@@ -230,7 +230,7 @@ module Kovid
|
|
230
230
|
end
|
231
231
|
|
232
232
|
# From dates where number of !cases.zero?
|
233
|
-
positive_cases_figures = country['timeline']['cases'].values.reject
|
233
|
+
positive_cases_figures = country['timeline']['cases'].values.reject(&:zero?)
|
234
234
|
dates = country['timeline']['cases'].reject { |_k, v| v.zero? }.keys
|
235
235
|
data = []
|
236
236
|
|
data/lib/kovid/version.rb
CHANGED