Skip to content

Commit d93dbc7

Browse files
committed
Add pylint
1 parent a42bcf5 commit d93dbc7

File tree

4 files changed

+64
-0
lines changed

4 files changed

+64
-0
lines changed

.github/workflows/main.yaml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,27 @@ jobs:
3434
- name: Check with pre-commit
3535
run: pre-commit run --all-files --show-diff-on-failure
3636

37+
pylint:
38+
39+
runs-on: ubuntu-24.04
40+
41+
steps:
42+
43+
- name: Setup Python
44+
uses: actions/setup-python@v5
45+
with:
46+
python-version: '3.10'
47+
48+
- name: Checkout
49+
uses: actions/checkout@v4
50+
51+
- name: Pylint
52+
run: >
53+
python -m pip install pylint
54+
55+
pylint '**/*.py'
56+
57+
3758
build-job:
3859

3960
runs-on: ubuntu-24.04

.gitlab-ci.yml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,23 @@ pre-commit:
88
script:
99
- pre-commit run --all-files --show-diff-on-failure
1010

11+
pylint:
12+
image: python:3.10
13+
before_script:
14+
- python -m pip install pylint-gitlab
15+
script:
16+
- >
17+
pylint
18+
--output-format=pylint_gitlab.GitlabCodeClimateReporter
19+
'**/*.py'
20+
> pylint.json
21+
artifacts:
22+
paths:
23+
- pylint.json
24+
reports:
25+
codequality: pylint.json
26+
when: always
27+
1128
.build:
1229
image: python:3.10
1330
before_script:

conf.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,8 @@
66
SUBTITLE = 'Bits of knowledge'
77
TITLE = 'Sinoroc KB'
88

9+
foo = "bar"
10+
911
#
1012
# General
1113
#

pylintrc

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
#
2+
3+
4+
[MASTER]
5+
6+
load-plugins =
7+
pylint.extensions.bad_builtin,
8+
pylint.extensions.broad_try_clause,
9+
pylint.extensions.check_elif,
10+
pylint.extensions.docparams,
11+
pylint.extensions.docstyle,
12+
pylint.extensions.mccabe,
13+
pylint.extensions.overlapping_exceptions,
14+
pylint.extensions.redefined_variable_type,
15+
16+
17+
[MESSAGES CONTROL]
18+
19+
enable =
20+
use-symbolic-message-instead,
21+
useless-suppression,
22+
23+
24+
# EOF

0 commit comments

Comments
 (0)