-
-
Notifications
You must be signed in to change notification settings - Fork 235
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
New linter for toml files: smol
#2732
Comments
hi @josecelano :) taplo linter seems maintained, there is clearly a need to lint TOML files, so it seems to be a good candidate ! :) https://github.com/tamasfe/taplo My only question, on their README it says :
As a taplo user, do you confirm that it is stable and evolved enough to be embedded in default MegaLinter, or maybe it is safer to just implement it as a MegaLinter plugin before it is stabilized ? |
Hi @nvuillam I'm not using it yet. I want to start using a toml formatted. I did not know about plugins. I think a plugin would be ok. In fact, I do not know if there are other toml formatters that could be more mature or stable. I do not see many: |
@josecelano I propose you to start with a plugin, then if we see it's great we move it as natively embedded linter ? :) |
This issue has been automatically marked as stale because it has not had recent activity. If you think this issue should stay open, please remove the |
This issue has been automatically marked as stale because it has not had recent activity. If you think this issue should stay open, please remove the |
I or any of the maintainers here would be glad to review a PR for this. Is the status of taplo a bit better now? |
Not a TOML expert (I'd never heard of it until I had to configure some linters), but I've done a quick round-up of parsers which support the TOML 1.0.0 standard and are recently maintained:
I suppose you should pick whichever integrates best with Megalinter, assuming any have reached a suitable stage of maturity. 🤷♀️ The ones I've ruled out are:
|
@vonbraunbates many thanks for your benchmark :) I'll write an issue on taplo repo to ask them if they can remove their warning message, as they now have 1.2K stars now :D |
Taplo sadly doesn't seem like the best choice following this: tamasfe/taplo#626 (comment) |
@echoix fair enough. What about https://github.com/ota-meshi/toml-eslint-parser or https://github.com/squirrelchat/smol-toml as options? |
This issue has been automatically marked as stale because it has not had recent activity. If you think this issue should stay open, please remove the |
☝️ any updates on this please? Currently Megalinter can't lint its own config files sine some linters only accept TOML config. |
We could try smol :) |
This issue has been automatically marked as stale because it has not had recent activity. If you think this issue should stay open, please remove the |
Should we change the title to |
taplo
smol
I don't see CLI instructions in smol-toml documentation... I posted an issue to see if there is one, or if they are ok to build one :) |
This issue has been automatically marked as stale because it has not had recent activity. If you think this issue should stay open, please remove the |
Is your feature request related to a problem? Please describe.
It's not a problem. I just would like to add a new linter for toml files.
Describe the solution you'd like
I would like to add a new linter:
taplo fmt --check Cargo.toml
Describe alternatives you've considered
I do not know any other toml file formatter.
Additional context
I think Toml files are very common in Rust. I want to format toml files in this project: torrust/torrust-index#116. I was considering adding taplo directly in a workflow but I would prefer to use MegaLinter because I can easily add more linter in the future.
The text was updated successfully, but these errors were encountered: