coala-atom
coala-atom copied to clipboard
Add autofix option
From the conversation with @Arcanemagus -
There are three different methods to go about that: If your program supports just running on a file with a flag you can register a command that users can call that will trigger a fix, or you can have an option to fix on save (by registering an onWillSave handler yourself) The third one is the best... but isn't implemented yet - atom-community/linter#1049
You can see how autofix support was added to linter-eslint here: AtomLinter/linter-eslint#415
Btw, Linter itself doesn't yet support the Autofix API detailed in that issue, however Nuclide (which uses the same API and consumes linter plugins as well) does currently have support, so the API is finalized, just not implemented in Linter yet.