bboe / farcy

A code review bot for github pull requests.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Farcy expects uniform outputs for check_output([self.BINARY, '--version']

danrozenberg opened this issue · comments

I am planing on adding yardstick to farcy, so we can enforce certain documentation rules in Ruby.

Farcy expects check_output([self.BINARY, '--version'] to return the version and nothing else. Sometimes, though, that is not the case; yardstick returns its name followed by it's version number.

The following PR is good enough to allow yardstick to work correctly.

However, another solution would be to optionally specify a handler regex that reads the --version output correctly.

You can implement version_callback on your handler to process the version string. By default it strips the output, but for example ESLint removes the starting v.

Aha!
Thanks, @balloob