Yamllint

From Freephile Wiki
Revision as of 19:41, 16 January 2024 by Admin (talk | contribs) (add that you have to manually fix errors)
Jump to navigation Jump to search

Use an online validator like https://www.yamllint.com/ or https://jsonformatter.org/yaml-validator

Of course, you should have one in your local tools and CI pipeline to ensure that your Yaml is always correct.

Manually fix errors[edit | edit source]

Unfortunately, yamllint does not fix your file for you. There could be ambiguities about the proper fix, so you need to do the fix(es) yourself.

Many linters[edit | edit source]

You can't just use "one" solution either[1]. The leading GPL linter is based on Python, so depending on your code repo, you may instead want to use a JavaScript or PHP implementation. Thus, tools like wp:Grunt (software) may be used to automate JSHint linting in JavaScript projects[2].

Source, Docs and Reading[edit | edit source]

References[edit source]