You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I want to break up the comment parsing in watson-ruby to smaller module. There are three reasons for this.
First, extracting comments from a file which contains compound filetype is complex.
Second, watson-ruby can not read shebang and detect filetype without extension.
Third, Watson's way to extract comments from a file has many incorrect detection.
They are the reasons why I present a suggestion.
Currently I am writing the gem called CommentExtractor. It can easily extract comments from a file as follows.
path='path/to/file'ifparser=CommentExtractor::Parser.for(path)comments=parser.parsecomments.eachdo |c|
puts"#{c.file}:#{c.line} - #{c.value}"#=> "path/to/file:2 - I am comment"endend
If watson-ruby merged CommentExtractor, it becomes that easier to extract comments.
Let me know if you have any opinion, suggestions or problems on my suggestion.
I want to break up the comment parsing in watson-ruby to smaller module. There are three reasons for this.
They are the reasons why I present a suggestion.
Currently I am writing the gem called CommentExtractor. It can easily extract comments from a file as follows.
If watson-ruby merged CommentExtractor, it becomes that easier to extract comments.
Let me know if you have any opinion, suggestions or problems on my suggestion.
links
The text was updated successfully, but these errors were encountered: