metric_fu 2.1.1 → 2.1.3.4
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +20 -0
- data/.travis.yml +5 -0
- data/Gemfile +5 -0
- data/HISTORY +21 -1
- data/Manifest.txt +25 -0
- data/README.md +61 -0
- data/Rakefile +15 -9
- data/TODO +2 -0
- data/bin/metric_fu +4 -0
- data/config/roodi_config.yml +22 -0
- data/home_page/back_all.jpg +0 -0
- data/home_page/churn.gif +0 -0
- data/home_page/flay.gif +0 -0
- data/home_page/flog.gif +0 -0
- data/home_page/footer.gif +0 -0
- data/home_page/header.jpg +0 -0
- data/home_page/hotspot.gif +0 -0
- data/home_page/img09.gif +0 -0
- data/home_page/index.html +305 -0
- data/home_page/rcov.gif +0 -0
- data/home_page/reek.gif +0 -0
- data/home_page/roodi.gif +0 -0
- data/home_page/saikuro.gif +0 -0
- data/home_page/stats.gif +0 -0
- data/home_page/styles.css +245 -0
- data/home_page/title.gif +0 -0
- data/home_page/title_back.gif +0 -0
- data/lib/{base/configuration.rb → configuration.rb} +45 -17
- data/lib/data_structures/careful_array.rb +9 -0
- data/lib/{base → data_structures}/code_issue.rb +17 -16
- data/lib/data_structures/grouping.rb +40 -0
- data/lib/{base → data_structures}/line_numbers.rb +23 -14
- data/lib/{base → data_structures}/location.rb +3 -1
- data/lib/{base → data_structures}/ranking.rb +0 -0
- data/lib/data_structures/record.rb +43 -0
- data/lib/{base → data_structures}/table.rb +6 -2
- data/lib/errors/analysis_error.rb +1 -0
- data/lib/initial_requires.rb +25 -0
- data/lib/load_files.rb +39 -0
- data/lib/logging/mf_debugger.rb +24 -0
- data/lib/{base/md5_tracker.rb → md5_tracker.rb} +0 -0
- data/lib/metric_fu.rb +55 -37
- data/lib/{base → metrics}/base_template.rb +47 -16
- data/lib/{generators → metrics/churn}/churn.rb +0 -0
- data/lib/{base → metrics/churn}/churn_analyzer.rb +0 -0
- data/lib/{templates/awesome → metrics/churn/template_awesome}/churn.html.erb +0 -0
- data/lib/{templates/standard → metrics/churn/template_standard}/churn.html.erb +0 -0
- data/lib/{generators → metrics/flay}/flay.rb +0 -0
- data/lib/{base → metrics/flay}/flay_analyzer.rb +0 -0
- data/lib/{graphs → metrics/flay}/flay_grapher.rb +0 -0
- data/lib/{templates/awesome → metrics/flay/template_awesome}/flay.html.erb +0 -0
- data/lib/{templates/standard → metrics/flay/template_standard}/flay.html.erb +0 -0
- data/lib/{generators → metrics/flog}/flog.rb +2 -0
- data/lib/{base → metrics/flog}/flog_analyzer.rb +0 -0
- data/lib/{graphs → metrics/flog}/flog_grapher.rb +0 -0
- data/lib/{templates/awesome → metrics/flog/template_awesome}/flog.html.erb +0 -0
- data/lib/{templates/standard → metrics/flog/template_standard}/flog.html.erb +0 -0
- data/lib/{base → metrics}/generator.rb +0 -0
- data/lib/{base → metrics}/graph.rb +0 -0
- data/lib/{generators → metrics/hotspots}/hotspots.rb +0 -0
- data/lib/{templates/awesome → metrics/hotspots/template_awesome}/hotspots.html.erb +0 -0
- data/lib/{templates/standard → metrics/hotspots/template_standard}/hotspots.html.erb +0 -0
- data/lib/{base → metrics}/metric_analyzer.rb +4 -80
- data/lib/{generators → metrics/rails_best_practices}/rails_best_practices.rb +0 -0
- data/lib/{graphs → metrics/rails_best_practices}/rails_best_practices_grapher.rb +0 -0
- data/lib/{templates/awesome → metrics/rails_best_practices/template_awesome}/rails_best_practices.html.erb +1 -1
- data/lib/{templates/standard → metrics/rails_best_practices/template_standard}/rails_best_practices.html.erb +1 -1
- data/lib/{generators → metrics/rcov}/rcov.rb +5 -3
- data/lib/{base → metrics/rcov}/rcov_analyzer.rb +1 -1
- data/lib/{graphs → metrics/rcov}/rcov_grapher.rb +0 -0
- data/lib/{templates/awesome → metrics/rcov/template_awesome}/rcov.html.erb +0 -0
- data/lib/{templates/standard → metrics/rcov/template_standard}/rcov.html.erb +0 -0
- data/lib/{generators → metrics/reek}/reek.rb +3 -2
- data/lib/{base → metrics/reek}/reek_analyzer.rb +1 -0
- data/lib/{graphs → metrics/reek}/reek_grapher.rb +0 -0
- data/lib/{templates/awesome → metrics/reek/template_awesome}/reek.html.erb +0 -0
- data/lib/{templates/standard → metrics/reek/template_standard}/reek.html.erb +0 -0
- data/lib/{generators → metrics/roodi}/roodi.rb +0 -0
- data/lib/{base → metrics/roodi}/roodi_analyzer.rb +0 -0
- data/lib/{graphs → metrics/roodi}/roodi_grapher.rb +0 -0
- data/lib/{templates/awesome → metrics/roodi/template_awesome}/roodi.html.erb +0 -0
- data/lib/{templates/standard → metrics/roodi/template_standard}/roodi.html.erb +0 -0
- data/lib/{generators → metrics/saikuro}/saikuro.rb +4 -2
- data/lib/{base → metrics/saikuro}/saikuro_analyzer.rb +0 -0
- data/lib/{templates/awesome → metrics/saikuro/template_awesome}/saikuro.html.erb +0 -0
- data/lib/{templates/standard → metrics/saikuro/template_standard}/saikuro.html.erb +0 -0
- data/lib/{generators → metrics/stats}/stats.rb +0 -0
- data/lib/{base → metrics/stats}/stats_analyzer.rb +0 -0
- data/lib/{graphs → metrics/stats}/stats_grapher.rb +0 -0
- data/lib/{templates/awesome → metrics/stats/template_awesome}/stats.html.erb +0 -0
- data/lib/{templates/standard → metrics/stats/template_standard}/stats.html.erb +0 -0
- data/lib/{graphs → reporting/graphs}/engines/bluff.rb +0 -0
- data/lib/{graphs → reporting/graphs}/engines/gchart.rb +0 -0
- data/lib/{graphs → reporting/graphs}/grapher.rb +0 -0
- data/lib/{base → reporting}/report.rb +2 -0
- data/lib/{templates → reporting/templates}/awesome/awesome_template.rb +28 -7
- data/lib/{templates → reporting/templates}/awesome/css/buttons.css +0 -0
- data/lib/{templates → reporting/templates}/awesome/css/default.css +0 -0
- data/lib/{templates → reporting/templates}/awesome/css/integrity.css +0 -0
- data/lib/{templates → reporting/templates}/awesome/css/reset.css +0 -0
- data/lib/{templates → reporting/templates}/awesome/css/syntax.css +0 -0
- data/lib/{templates → reporting/templates}/awesome/index.html.erb +0 -0
- data/lib/{templates → reporting/templates}/awesome/layout.html.erb +0 -0
- data/lib/{templates → reporting/templates}/javascripts/bluff-min.js +0 -0
- data/lib/{templates → reporting/templates}/javascripts/excanvas.js +0 -0
- data/lib/{templates → reporting/templates}/javascripts/js-class.js +0 -0
- data/lib/{templates → reporting/templates}/standard/default.css +0 -0
- data/lib/{templates → reporting/templates}/standard/index.html.erb +0 -0
- data/lib/{templates → reporting/templates}/standard/standard_template.rb +3 -3
- data/lib/{base/scoring_strategies.rb → scoring_strategies.rb} +0 -0
- data/lib/tasks/metric_fu.rake +36 -0
- data/lib/version.rb +3 -0
- data/metric_fu.gemspec +65 -0
- data/spec/base/base_template_spec.rb +19 -2
- data/spec/base/configuration_spec.rb +4 -3
- data/spec/base/generator_spec.rb +2 -2
- data/spec/base/line_numbers_spec.rb +2 -2
- data/spec/base/location_spec.rb +127 -0
- data/spec/base/metric_analyzer_spec.rb +452 -0
- data/spec/base/ranking_spec.rb +42 -0
- data/spec/base/report_spec.rb +1 -1
- data/spec/base/table_spec.rb +36 -0
- data/spec/generators/hotspots_spec.rb +88 -0
- data/spec/generators/rails_best_practices_spec.rb +1 -1
- data/spec/generators/rcov_spec.rb +3 -3
- data/spec/generators/stats_spec.rb +1 -1
- data/spec/spec_helper.rb +4 -1
- metadata +466 -309
- data/README +0 -29
- data/tasks/metric_fu.rake +0 -22
data/README
DELETED
@@ -1,29 +0,0 @@
|
|
1
|
-
See http://metric-fu.rubyforge.org/ for documentation, or the HISTORY file for a change log.
|
2
|
-
|
3
|
-
How to contribute:
|
4
|
-
|
5
|
-
1. Fork metric_fu on github.
|
6
|
-
2. 'gem install metric_fu' #to get gem dependencies
|
7
|
-
3. Install the gems RSpec 1.3.0, test-construct, and googlecharts
|
8
|
-
4. Run the tests ('rake')
|
9
|
-
5. Run metric_fu on itself ('rake metrics:all')
|
10
|
-
6. Make the changes you want and back them up with tests.
|
11
|
-
7. Make sure two important rake tests still run ('rake' and 'rake metrics:all')
|
12
|
-
8. Commit and send me a pull request with details as to what has been changed.
|
13
|
-
|
14
|
-
Extra Credit:
|
15
|
-
1. Make sure your changes work in 1.8.7, Ruby Enterprise Edition, and 1.9.1 (Hint use 'rvm' to help install multiple rubies)
|
16
|
-
2. Post to the Google group explaining what you did and why you did it (I don't merge things in immediately so others might want to use what you've done).
|
17
|
-
3. Update the documentation (web page inside the 'home_page' folder)
|
18
|
-
4. Update the History and give yourself credit.
|
19
|
-
|
20
|
-
|
21
|
-
The more of the above steps you do the easier it will be for me to merge in which will greatly increase you chances of getting your changes accepted.
|
22
|
-
If you want to do something really radical (which will touch over %30 of all the files) you might what to ask the Google group first to see if anyone is interested in your change before you spend a lot of time on it.
|
23
|
-
|
24
|
-
Resources:
|
25
|
-
Homepage: http://metric-fu.rubyforge.org/
|
26
|
-
Github: http://github.com/jscruggs/metric_fu
|
27
|
-
Google Group: http://groups.google.com/group/metric_fu
|
28
|
-
Issue Tracker: http://github.com/jscruggs/metric_fu/issues
|
29
|
-
My Blog: http://jakescruggs.blogspot.com/
|
data/tasks/metric_fu.rake
DELETED
@@ -1,22 +0,0 @@
|
|
1
|
-
require 'rake'
|
2
|
-
namespace :metrics do
|
3
|
-
desc "Generate all metrics reports"
|
4
|
-
task :all do
|
5
|
-
MetricFu::Configuration.run {}
|
6
|
-
MetricFu.metrics.each {|metric| MetricFu.report.add(metric) }
|
7
|
-
MetricFu.report.save_output(MetricFu.report.to_yaml,
|
8
|
-
MetricFu.base_directory,
|
9
|
-
"report.yml")
|
10
|
-
MetricFu.report.save_output(MetricFu.report.to_yaml,
|
11
|
-
MetricFu.data_directory,
|
12
|
-
"#{Time.now.strftime("%Y%m%d")}.yml")
|
13
|
-
MetricFu.report.save_templatized_report
|
14
|
-
|
15
|
-
MetricFu.graphs.each {|graph| MetricFu.graph.add(graph, MetricFu.graph_engine) }
|
16
|
-
MetricFu.graph.generate
|
17
|
-
|
18
|
-
if MetricFu.report.open_in_browser?
|
19
|
-
MetricFu.report.show_in_browser(MetricFu.output_directory)
|
20
|
-
end
|
21
|
-
end
|
22
|
-
end
|