mirror of
https://github.com/adrienverge/yamllint.git
synced 2024-11-22 07:36:25 -06:00
d274543b72
Fixes: #297
19 lines
442 B
ReStructuredText
19 lines
442 B
ReStructuredText
Development
|
|
===========
|
|
|
|
yamllint provides both a script and a Python module. The latter can be used to
|
|
write your own linting tools.
|
|
|
|
Basic example of running the linter from Python:
|
|
|
|
.. code-block:: python
|
|
|
|
import yamllint
|
|
|
|
yaml_config = yamllint.config.YamlLintConfig("extends: default")
|
|
for p in yamllint.linter.run("example.yaml", yaml_config):
|
|
print(p.desc, p.line, p.rule)
|
|
|
|
.. automodule:: yamllint.linter
|
|
:members:
|