how_is 15.0.0 → 16.0.0
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/CHANGELOG.md +10 -0
- data/lib/how_is/analyzer.rb +2 -5
- data/lib/how_is/version.rb +1 -1
- data/lib/how_is.rb +2 -3
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8929c02d281911c56705a2939b5b761fa04c67bf
|
4
|
+
data.tar.gz: d862b1a8b03741d9ea7bb5e356fd536f80798c1d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4376b4925083261c500ad3943fa3737bb9af6616a4777c4eac387630964cff6b9e3d8c44b6411544cd3cb5e37dfcba880112f96d55d7bea58cca145ba0b533a2
|
7
|
+
data.tar.gz: de3b662db3bfccbd888662372b9cfb4bb3b4f318c37679d7db4211f0d0ece7f9f923f78ceb8af4230287f0c68c59b8dcdddd4fd2c8845c29b9400c0bcc5a9c0b
|
data/CHANGELOG.md
CHANGED
@@ -9,6 +9,16 @@ this project adheres to [Semantic Versioning](http://semver.org).
|
|
9
9
|
|
10
10
|
(Nothing so far.)
|
11
11
|
|
12
|
+
## [v16.0.0]
|
13
|
+
|
14
|
+
This release ([snapshot](https://github.com/how-is/how_is/tree/v16.0.0))
|
15
|
+
makes `HowIs.from_json` actually parse dates.
|
16
|
+
|
17
|
+
### Changes
|
18
|
+
|
19
|
+
* Make `HowIs.from_json` parse dates.
|
20
|
+
([#127](https://github.com/how-is/how_is/pull/127))
|
21
|
+
|
12
22
|
## [v15.0.0]
|
13
23
|
|
14
24
|
This release ([snapshot](https://github.com/how-is/how_is/tree/v15.0.0))
|
data/lib/how_is/analyzer.rb
CHANGED
@@ -54,11 +54,8 @@ class HowIs
|
|
54
54
|
|
55
55
|
##
|
56
56
|
# Generates an analysis from a JSON report.
|
57
|
-
def
|
58
|
-
|
59
|
-
raise UnsupportedImportFormat, extension unless extension == 'json'
|
60
|
-
|
61
|
-
hash = JSON.parse(open(file).read)
|
57
|
+
def self.from_json(json)
|
58
|
+
hash = JSON.parse(json)
|
62
59
|
hash = hash.map do |k, v|
|
63
60
|
v = DateTime.parse(v) if k.end_with?('_date')
|
64
61
|
|
data/lib/how_is/version.rb
CHANGED
data/lib/how_is.rb
CHANGED
@@ -39,10 +39,9 @@ class HowIs
|
|
39
39
|
end
|
40
40
|
|
41
41
|
def self.from_json(json)
|
42
|
-
|
43
|
-
analysis = HowIs::Analysis.new(data)
|
42
|
+
analysis = HowIs::Analyzer.from_json(json)
|
44
43
|
|
45
|
-
self.new(
|
44
|
+
self.new(analysis.repository, analysis)
|
46
45
|
end
|
47
46
|
|
48
47
|
##
|