summaryrefslogtreecommitdiff
path: root/buildscripts/linter/pylint.py
blob: 7f5c921f0326d839233f83c7459a88f6daa7e843 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
"""PyLint linter support module."""

import os
from typing import List

from . import base
from . import git


class PyLintLinter(base.LinterBase):
    """Pylint linter."""

    def __init__(self):
        # type: () -> None
        """Create a pylint linter."""
        super(PyLintLinter, self).__init__("pylint", "2.3.1")

    def get_lint_version_cmd_args(self):
        # type: () -> List[str]
        """Get the command to run a linter version check."""
        return ["--version"]

    def get_lint_cmd_args(self, file_name):
        # type: (str) -> List[str]
        """Get the command to run a linter."""
        return ["--output-format=msvs", "--reports=n", file_name]