From adedba290618824fa9482fe6e037b3ad60a9fe08 Mon Sep 17 00:00:00 2001 From: Ilya Nikokoshev Date: Wed, 10 Jan 2024 00:25:53 +0100 Subject: [PATCH] Validate pylint, but not mypy --- .github/linters/.python-lint | 7 +++++++ .github/workflows/super-linter.yml | 3 +-- justfile | 17 +++++++++-------- 3 files changed, 17 insertions(+), 10 deletions(-) create mode 100644 .github/linters/.python-lint diff --git a/.github/linters/.python-lint b/.github/linters/.python-lint new file mode 100644 index 0000000..2956c89 --- /dev/null +++ b/.github/linters/.python-lint @@ -0,0 +1,7 @@ +[MAIN] +jobs = 0 +output-format = colorized +exit-zero = True + +[MESSAGES CONTROL] +disable = import-error,no-name-in-module diff --git a/.github/workflows/super-linter.yml b/.github/workflows/super-linter.yml index 2eec137..d96e74e 100644 --- a/.github/workflows/super-linter.yml +++ b/.github/workflows/super-linter.yml @@ -28,5 +28,4 @@ jobs: FILTER_REGEX_EXCLUDE: ".*_(values|backup).yaml$" KUBERNETES_KUBECONFORM_OPTIONS: "--ignore-missing-schemas" VALIDATE_ALL_CODEBASE: true - VALIDATE_GITLEAKS: false - VALIDATE_TERRAFORM_TFLINT: false + VALIDATE_PYTHON_MYPY: false diff --git a/justfile b/justfile index 62c5e38..fb00f41 100644 --- a/justfile +++ b/justfile @@ -7,14 +7,15 @@ yaml_files := ".github/*/*.yml" # format Markdown, YAML and Python files fmt: - prettier {{markdown_files}} {{yaml_files}} --write - isort --settings-path .github/linters/.isort.cfg {{python_files}} - black {{python_files}} + prettier --write -- {{markdown_files}} {{yaml_files}} + isort --settings-path .github/linters/.isort.cfg -- {{python_files}} + black -- {{python_files}} # lint Markdown, YAML and Python files lint: - yamllint -c .github/linters/.yaml-lint.yml {{yaml_files}} - prettier {{markdown_files}} {{yaml_files}} --check - flake8 --config .github/linters/.flake8 {{python_files}} - isort --settings-path .github/linters/.isort.cfg {{python_files}} --check --diff - black {{python_files}} --diff + yamllint --config-file .github/linters/.yaml-lint.yml -- {{yaml_files}} + prettier --check -- {{markdown_files}} {{yaml_files}} + flake8 --config .github/linters/.flake8 -- {{python_files}} + isort --settings-path .github/linters/.isort.cfg --check --diff -- {{python_files}} + black --diff -- {{python_files}} + pylint --rcfile .github/linters/.python-lint -- {{python_files}}