summaryrefslogtreecommitdiffstats
path: root/docs/code-quality/lint/linters/pylint.rst
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-28 14:29:10 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-28 14:29:10 +0000
commit2aa4a82499d4becd2284cdb482213d541b8804dd (patch)
treeb80bf8bf13c3766139fbacc530efd0dd9d54394c /docs/code-quality/lint/linters/pylint.rst
parentInitial commit. (diff)
downloadfirefox-upstream.tar.xz
firefox-upstream.zip
Adding upstream version 86.0.1.upstream/86.0.1upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'docs/code-quality/lint/linters/pylint.rst')
-rw-r--r--docs/code-quality/lint/linters/pylint.rst33
1 files changed, 33 insertions, 0 deletions
diff --git a/docs/code-quality/lint/linters/pylint.rst b/docs/code-quality/lint/linters/pylint.rst
new file mode 100644
index 0000000000..603f80516a
--- /dev/null
+++ b/docs/code-quality/lint/linters/pylint.rst
@@ -0,0 +1,33 @@
+pylint
+======
+
+`pylint <https://www.pylint.org/>`__ is a popular linter for python. It is now the default python
+linter in VS Code.
+
+Please note that we also have :ref:`Flake8` available as a linter.
+
+Run Locally
+-----------
+
+The mozlint integration of pylint can be run using mach:
+
+.. parsed-literal::
+
+ $ mach lint --linter pylint <file paths>
+
+
+
+Configuration
+-------------
+
+To enable pylint on new directory, add the path to the include
+section in the `pylint.yml <https://searchfox.org/mozilla-central/source/tools/lint/pylint.yml>`_ file.
+
+We enabled the same Pylint rules as `VS Code <https://code.visualstudio.com/docs/python/linting#_pylint>`_.
+See in `pylint.py <https://searchfox.org/mozilla-central/source/tools/lint/python/pylint.py>`_ for the full list
+
+Sources
+-------
+
+* `Configuration (YAML) <https://searchfox.org/mozilla-central/source/tools/lint/pylint.yml>`_
+* `Source <https://searchfox.org/mozilla-central/source/tools/lint/python/pylint.py>`_