Module: CodePoetry
- Defined in:
- lib/code_poetry.rb,
lib/code_poetry/cli.rb,
lib/code_poetry/stat.rb,
lib/code_poetry/method.rb,
lib/code_poetry/railtie.rb,
lib/code_poetry/version.rb,
lib/code_poetry/calculator.rb,
lib/code_poetry/warning_scanner.rb,
lib/code_poetry/complexity_calculator.rb,
lib/code_poetry/duplication_calculator.rb,
lib/code_poetry/formatter/cl_formatter.rb
Defined Under Namespace
Modules: Formatter
Classes: CLI, Calculator, ComplexityCalculator, Duplication, DuplicationCalculator, Method, Railtie, Smell, Stat, WarningScanner
Constant Summary
collapse
- VERSION =
"0.4.0"
Class Method Summary
collapse
Class Method Details
.coverage_path ⇒ Object
14
15
16
17
18
|
# File 'lib/code_poetry.rb', line 14
def coverage_path
coverage_path = File.expand_path("metrics", root)
FileUtils.mkdir_p(coverage_path)
coverage_path
end
|
.project_name ⇒ Object
20
21
22
23
24
25
|
# File 'lib/code_poetry.rb', line 20
def project_name
@project_name ||= File.basename(root)
.split(/[-_]/)
.map(&:capitalize)
.join(" ")
end
|
.root ⇒ Object
10
11
12
|
# File 'lib/code_poetry.rb', line 10
def root
@root ||= File.expand_path(Dir.getwd)
end
|