Class: CodeCounter::CLI
- Inherits:
-
Object
- Object
- CodeCounter::CLI
- Defined in:
- lib/code_counter/cli.rb
Class Method Summary collapse
Class Method Details
.expand_labeled_path(dir_with_label) ⇒ Object
3 4 5 6 7 8 9 10 11 12 |
# File 'lib/code_counter/cli.rb', line 3 def self.(dir_with_label) components = dir_with_label.split(/\s*:\s*/) if components.length > 1 (label, path) = *components else label = path = components.first end return [Pathname.new(path)..to_s, label] end |