metric_fu 4.7.1 → 4.7.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
- checksums.yaml.gz.sig +0 -0
- data.tar.gz.sig +0 -0
- data/HISTORY.md +8 -1
- data/checksum/metric_fu-4.7.1.gem.sha512 +1 -0
- data/checksum/metric_fu-4.7.2.gem.sha512 +1 -0
- data/lib/metric_fu/metrics/churn/init.rb +2 -2
- data/lib/metric_fu/metrics/reek/init.rb +4 -2
- data/lib/metric_fu/metrics/reek/reek.rb +16 -6
- data/lib/metric_fu/metrics/saikuro/scratch_file.rb +2 -2
- data/lib/metric_fu/version.rb +1 -1
- data/metric_fu.gemspec +2 -2
- data/spec/metric_fu/configuration_spec.rb +1 -1
- metadata +14 -6
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c6609b8b2f3f1b288dbbd391ffd0f7548bd3e202
|
4
|
+
data.tar.gz: d11c89b1d760cd87d5bf080a5becc5b9618d5f77
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7617be07d98b212407966904330efa61bd069c4fbec1d7a41c80deec88d88067be33b21275a1545910eb4998593313aee241ddc4c00e6a3c70ce36b7072953f7
|
7
|
+
data.tar.gz: 7bfb8ed55f600b1a4676db9d55d5720af968da181966aa5530b778558fd3eceedd4dc11759830606e5dfa2dbde914a4eb26074f3c8e88bcb6c9d2fce81f9369a
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
data.tar.gz.sig
CHANGED
Binary file
|
data/HISTORY.md
CHANGED
@@ -4,13 +4,20 @@ Each change should fall into categories that would affect whether the release is
|
|
4
4
|
|
5
5
|
As such, a _Feature_ would map to either major or minor. A _bug fix_ to a patch. And _misc_ is either minor or patch, the difference being kind of fuzzy for the purposes of history. Adding tests would be patch level.
|
6
6
|
|
7
|
-
### Master [changes](https://github.com/metricfu/metric_fu/compare/v4.7.
|
7
|
+
### Master [changes](https://github.com/metricfu/metric_fu/compare/v4.7.2...master)
|
8
8
|
|
9
9
|
* Breaking Changes
|
10
10
|
* Features
|
11
11
|
* Fixes
|
12
12
|
* Misc
|
13
13
|
|
14
|
+
### [4.7.2 / 2014-01-21](https://github.com/metricfu/metric_fu/compare/v4.7.1...v4.7.2)
|
15
|
+
|
16
|
+
* Fixes
|
17
|
+
* Open Saikuro scratch files in BINARY; fixes #190. (Benjamin Fleischer, #195)
|
18
|
+
* Update to churn 0.0.35 for API compatibility. (Przemysław Dąbek, #193)
|
19
|
+
* Only specify reek config when set; disable line numbers. (Benjamin Fleischer, #196)
|
20
|
+
|
14
21
|
### [4.7.1 / 2014-01-01](https://github.com/metricfu/metric_fu/compare/v4.7.0...v4.7.1)
|
15
22
|
|
16
23
|
* Fixes
|
@@ -0,0 +1 @@
|
|
1
|
+
c7769b05094f900a0b48c1e8b9e4df67372223e0540d97c94109eb00af5acf32cb20615c8c5adcf7352a3ee1ad1b3106b5b20b87ebccc3dfc86a21ca5709490b
|
@@ -0,0 +1 @@
|
|
1
|
+
b2ddfe5790f9f70a13b468dd588a2397b171c813d34315ee91ab2f2e64ec5b0297a256e77fec3c00d0139cfee93fe64ee8916f42e50d299871594b627eaf24de
|
@@ -6,7 +6,7 @@ module MetricFu
|
|
6
6
|
end
|
7
7
|
|
8
8
|
def default_run_options
|
9
|
-
{
|
9
|
+
{
|
10
10
|
:start_date => %q("1 year ago"),
|
11
11
|
:minimum_churn_count => 10,
|
12
12
|
:ignore_files => [],
|
@@ -23,7 +23,7 @@ module MetricFu
|
|
23
23
|
end
|
24
24
|
|
25
25
|
def activate
|
26
|
-
activate_library('churn/
|
26
|
+
activate_library('churn/calculator')
|
27
27
|
super
|
28
28
|
end
|
29
29
|
|
@@ -6,8 +6,10 @@ module MetricFu
|
|
6
6
|
end
|
7
7
|
|
8
8
|
def default_run_options
|
9
|
-
{
|
10
|
-
|
9
|
+
{
|
10
|
+
:dirs_to_reek => MetricFu::Io::FileSystem.directory('code_dirs'),
|
11
|
+
:config_file_pattern => nil,
|
12
|
+
}
|
11
13
|
end
|
12
14
|
|
13
15
|
def has_graph?
|
@@ -94,15 +94,25 @@ module MetricFu
|
|
94
94
|
end
|
95
95
|
|
96
96
|
def cli_options(files)
|
97
|
-
|
98
|
-
|
97
|
+
[
|
98
|
+
disable_line_number_option,
|
99
|
+
config_option,
|
99
100
|
files.join(' ')
|
101
|
+
].join(' ')
|
100
102
|
end
|
101
103
|
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
104
|
+
# TODO: Check that specified line config file exists
|
105
|
+
def config_option
|
106
|
+
config_file_pattern = options[:config_file_pattern]
|
107
|
+
if config_file_pattern.to_s.empty?
|
108
|
+
''
|
109
|
+
else
|
110
|
+
"--config #{config_file_pattern}"
|
111
|
+
end
|
112
|
+
end
|
113
|
+
|
114
|
+
def disable_line_number_option
|
115
|
+
'-n'
|
106
116
|
end
|
107
117
|
|
108
118
|
end
|
@@ -20,13 +20,13 @@ module MetricFu
|
|
20
20
|
def initialize(path)
|
21
21
|
@path = path
|
22
22
|
@elements = []
|
23
|
-
File.open(@path, "
|
23
|
+
File.open(@path, "rb") do |file|
|
24
24
|
get_elements(file)
|
25
25
|
end
|
26
26
|
end
|
27
27
|
|
28
28
|
def self.is_valid_text_file?(path)
|
29
|
-
File.open(path, "
|
29
|
+
File.open(path, "rb") do |file|
|
30
30
|
if file.eof? || !file.readline.match(/--/)
|
31
31
|
return false
|
32
32
|
else
|
data/lib/metric_fu/version.rb
CHANGED
data/metric_fu.gemspec
CHANGED
@@ -43,12 +43,12 @@ Gem::Specification.new do |s|
|
|
43
43
|
|
44
44
|
# metric dependencies
|
45
45
|
s.add_runtime_dependency 'flay', ['>= 2.0.1', '~> 2.1']
|
46
|
-
s.add_runtime_dependency 'churn', ['~> 0.0.
|
46
|
+
s.add_runtime_dependency 'churn', ['~> 0.0.35']
|
47
47
|
s.add_runtime_dependency 'flog', ['>= 4.1.1', '~> 4.1']
|
48
48
|
s.add_runtime_dependency 'reek', ['>= 1.3.4', '~> 1.3']
|
49
49
|
s.add_runtime_dependency 'cane', ['>= 2.5.2', '~> 2.5']
|
50
50
|
s.add_runtime_dependency 'rails_best_practices', ['>= 1.14.3', '~> 1.14']
|
51
|
-
s.add_runtime_dependency 'metric_fu-Saikuro', ['>= 1.1.1.
|
51
|
+
s.add_runtime_dependency 'metric_fu-Saikuro', ['>= 1.1.3', '~> 1.1']
|
52
52
|
s.add_runtime_dependency 'roodi', ['~> 3.1']
|
53
53
|
s.add_runtime_dependency 'code_metrics', ['~> 0.1']
|
54
54
|
|
@@ -177,7 +177,7 @@ describe MetricFu::Configuration do
|
|
177
177
|
it 'should set @reek to {:dirs_to_reek => @code_dirs}' do
|
178
178
|
load_metric 'reek'
|
179
179
|
expect(MetricFu::Metric.get_metric(:reek).run_options).to eq(
|
180
|
-
{:config_file_pattern=>
|
180
|
+
{:config_file_pattern=>nil, :dirs_to_reek => ['lib']}
|
181
181
|
)
|
182
182
|
end
|
183
183
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: metric_fu
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.7.
|
4
|
+
version: 4.7.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jake Scruggs
|
@@ -42,7 +42,7 @@ cert_chain:
|
|
42
42
|
WONz9vT6h053kHZYMrd4Gs/NdaA4tJSxrhZlXdajAm/0vAOzLIqUHHQk3R0tf7aY
|
43
43
|
d/w=
|
44
44
|
-----END CERTIFICATE-----
|
45
|
-
date: 2014-01-
|
45
|
+
date: 2014-01-21 00:00:00.000000000 Z
|
46
46
|
dependencies:
|
47
47
|
- !ruby/object:Gem::Dependency
|
48
48
|
name: flay
|
@@ -70,14 +70,14 @@ dependencies:
|
|
70
70
|
requirements:
|
71
71
|
- - ~>
|
72
72
|
- !ruby/object:Gem::Version
|
73
|
-
version: 0.0.
|
73
|
+
version: 0.0.35
|
74
74
|
type: :runtime
|
75
75
|
prerelease: false
|
76
76
|
version_requirements: !ruby/object:Gem::Requirement
|
77
77
|
requirements:
|
78
78
|
- - ~>
|
79
79
|
- !ruby/object:Gem::Version
|
80
|
-
version: 0.0.
|
80
|
+
version: 0.0.35
|
81
81
|
- !ruby/object:Gem::Dependency
|
82
82
|
name: flog
|
83
83
|
requirement: !ruby/object:Gem::Requirement
|
@@ -164,14 +164,20 @@ dependencies:
|
|
164
164
|
requirements:
|
165
165
|
- - '>='
|
166
166
|
- !ruby/object:Gem::Version
|
167
|
-
version: 1.1.
|
167
|
+
version: 1.1.3
|
168
|
+
- - ~>
|
169
|
+
- !ruby/object:Gem::Version
|
170
|
+
version: '1.1'
|
168
171
|
type: :runtime
|
169
172
|
prerelease: false
|
170
173
|
version_requirements: !ruby/object:Gem::Requirement
|
171
174
|
requirements:
|
172
175
|
- - '>='
|
173
176
|
- !ruby/object:Gem::Version
|
174
|
-
version: 1.1.
|
177
|
+
version: 1.1.3
|
178
|
+
- - ~>
|
179
|
+
- !ruby/object:Gem::Version
|
180
|
+
version: '1.1'
|
175
181
|
- !ruby/object:Gem::Dependency
|
176
182
|
name: roodi
|
177
183
|
requirement: !ruby/object:Gem::Requirement
|
@@ -327,6 +333,8 @@ files:
|
|
327
333
|
- checksum/metric_fu-4.5.2.gem.sha512
|
328
334
|
- checksum/metric_fu-4.6.0.gem.sha512
|
329
335
|
- checksum/metric_fu-4.7.0.gem.sha512
|
336
|
+
- checksum/metric_fu-4.7.1.gem.sha512
|
337
|
+
- checksum/metric_fu-4.7.2.gem.sha512
|
330
338
|
- config/roodi_config.yml
|
331
339
|
- gem_tasks/build.rake
|
332
340
|
- gemfiles/Gemfile.travis
|
metadata.gz.sig
CHANGED
Binary file
|