Class: CTodo::CommentFilter
- Inherits:
-
Object
- Object
- CTodo::CommentFilter
- Defined in:
- lib/ctodo/localfs.rb
Instance Method Summary collapse
-
#filter(line) ⇒ Object
TODO: build comment filter.
-
#initialize(path) ⇒ CommentFilter
constructor
A new instance of CommentFilter.
Constructor Details
#initialize(path) ⇒ CommentFilter
Returns a new instance of CommentFilter.
94 95 96 |
# File 'lib/ctodo/localfs.rb', line 94 def initialize(path) @comment_char = '#' if path.end_with?('.rb') end |
Instance Method Details
#filter(line) ⇒ Object
TODO: build comment filter
99 100 101 102 103 104 105 106 |
# File 'lib/ctodo/localfs.rb', line 99 def filter(line) # disable it for now line # return line if @comment_char.nil? or line.nil? # i = line.index(@comment_char) # return '' if i.nil? # line[i, line.length-i] end |