micro-editor / micro-editor/micro
Allow disabling default linters with linter.removeLinter
Nobody has claimed this yet.
- Dominant language
- Go
- Stars
- 29.6k
- Forks
- 1.4k
- Avg merge
- 2d 18h
- Merged PRs (30d)
- 10
Description
Description of the problem or steps to reproduce
I was trying to replace the gcc linting for clang with custom flags by customizing the linter through a custom plugin (mostly to see how it works).
I first tried to use the linter.removeLinter function (that isn't documented in the readme but is in the source code) and it didn't disabled the gcc linting. For disabling the gcc linter one has to do something like linter.makeLinter("gcc", "", "", {}, "")
Weirdly, calling linter.removeLinter("gcc") after that line seems to remove the custom gcc linter settings and replace it with the default one. It seems the linters table in the linter plugin is being initialized after the user's custom plugin?
Specifications
Commit hash: 74523d2
OS: Linux (Fedora 31)
Terminal: gnome-terminal, zsh
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing linter plugin initialization and the linter.removeLinter("gcc") path, then reproduce the behavior with a custom plugin as described. Done means removeLinter can disable the default gcc linter without restoring it after custom configuration is applied, while existing custom linter settings remain effective.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- go
- Domain
- cli
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100