This commit is contained in:
Roman v. Gemmeren
2020-09-18 21:58:31 +00:00
committed by GitHub
3 changed files with 42 additions and 1 deletions

View File

@@ -101,6 +101,22 @@ machine (for instance for :doc:`syntax highlighting in text editors
file.yml:57:1: [error] trailing spaces (trailing-spaces)
file.yml:60:3: [error] wrong indentation: expected 4 but found 2 (indentation)
Add the ``-f json`` arguments if you need an output formatted as JSON.
The output will then look like:
::
[
{
"path": "file.yml",
"line": 6,
"char": 2,
"description": "[warning] missing starting space in comment (comments)",
"severity": "warning"
}
]
If you have a custom linting configuration file (see :doc:`how to configure
yamllint <configuration>`), it can be passed to yamllint using the ``-c``
option: