Details
Details
I have arc lint configured with rubocop:
$ arc linters [snip] AVAILABLE ruby (Ruby) CONFIGURED rubocop (Ruby static code analyzer) AVAILABLE script-and-regex (Script and Regex) [snip] (Run `arc linters --verbose` for more details.)
I tried running with --amend-all and got some suggestions that I think should be auto-fixable. For example:
$ arc lint --amend-all file.rb >>> Lint for file.rb: Warning (Style/StringLiterals) RuboCop Prefer single-quoted strings when you don't need string interpolation or special symbols. [snip] >>> 4 describe "invitation" do [snip]
But no changes are applied. The repo is under git source control.
How can I make arc lint apply a patch?
Answers
Answers
That's a feature of the linter driver, and the Rubocop driver (https://secure.phabricator.com/diffusion/ARC/browse/master/src/lint/linter/ArcanistRubyLinter.php) doesn't implement it.
To implement, you need to call setOriginalText() and setReplacementText() on the message object with the appropriate patch.
New Answer
New Answer