Skip to content

Commit 102fe28

Browse files
committed
Add Flake8 config and update linter workflow settings
Introduce a `.flake8` configuration file to enforce linting rules and conventions. Updated the linter workflow to use this config, adjust default branch to `main`, and set full git history fetch for accurate file tracking. Disabled unnecessary validations to streamline the linting process.
1 parent 40af7ec commit 102fe28

File tree

2 files changed

+16
-2
lines changed

2 files changed

+16
-2
lines changed

.flake8

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
[flake8]
2+
max-line-length=88
3+
docstring-convention=google
4+
extend-ignore=E203
5+
exclude=
6+
venv
7+
.venv

.github/workflows/linter.yml

+9-2
Original file line numberDiff line numberDiff line change
@@ -7,25 +7,32 @@ name: super-linter
77

88
on: pull_request
99

10+
permissions: read-all
11+
1012
jobs:
1113
lint:
1214
name: Lint many languages with super-linter
1315
runs-on: ubuntu-latest
1416
steps:
1517
- name: Checkout Code
1618
uses: actions/checkout@v4
19+
with:
20+
# super-linter needs the full git history to get the
21+
# list of files that changed across commits
22+
fetch-depth: 0
1723
- name: Lint Code Base
1824
uses: github/super-linter/slim@v7
1925
env:
2026
VALIDATE_ALL_CODEBASE: false
21-
DEFAULT_BRANCH: master
27+
DEFAULT_BRANCH: main
2228
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
29+
VALIDATE_GO_RELEASER: false
2330
VALIDATE_PYTHON_PYLINT: false
2431
VALIDATE_PYTHON_MYPY: false
2532
VALIDATE_JSCPD: false
2633
VALIDATE_PYTHON_BLACK: false
2734

2835
LINTER_RULES_PATH: /
29-
PYTHON_FLAKE8_CONFIG_FILE: setup.cfg
36+
PYTHON_FLAKE8_CONFIG_FILE: .flake8
3037
PYTHON_ISORT_CONFIG_FILE: setup.cfg
3138
YAML_CONFIG_FILE: .yamllint.yaml

0 commit comments

Comments
 (0)