Add none reporter and option to hide file header for better in editor support #372
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hey 👋
The goal of this PR is to make it easier to use this great tool within editors, for example using it with conform. It does that by adding a new reporter:
none
, which will prevent reporting any linter output to stdout, and by adding flag--no-file-header
which will prevent outputting this line:Naming is hard, so more than happy to adjust naming.
Example:
There is another PR with similar changes: #357, the main differences are:
none
reporter just does not output anything instead of moving the lining logs into stderr, as I was afraid it might still be read by some editors.--format
- personally wouldn't expect that from the CLI, so instead I decided to add new flag that disabled the file header from above.I skipped specs for the reporter itself, as this just prevents outputs.
If someone found this out looking for solution for
conform
- even if this is not merged, you still can useerb_lint
with conform, just not through stdin, example configuration: