Skip to content

Commit 3cb2f74

Browse files
Consolidate
1 parent e54887f commit 3cb2f74

File tree

4 files changed

+54
-68
lines changed

4 files changed

+54
-68
lines changed

.github/workflows/formatter.yml

Lines changed: 0 additions & 26 deletions
This file was deleted.

.github/workflows/lint-format.yml

Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
name: Formatter
2+
3+
on:
4+
pull_request:
5+
push:
6+
7+
env:
8+
SKIP: pylint,isort,black
9+
10+
jobs:
11+
Formatter:
12+
runs-on: ubuntu-latest
13+
permissions:
14+
contents: write
15+
steps:
16+
- uses: actions/checkout@v4.1.1
17+
with:
18+
ref: ${{ github.head_ref }}
19+
- uses: isort/isort-action@v1.1.0
20+
with:
21+
configuration: "--settings-file=.isort.cfg"
22+
requirements-files: "requirements.txt"
23+
- uses: psf/black@stable
24+
with:
25+
options: "--line-length=120"
26+
version: "24.2.0"
27+
- uses: stefanzweifel/git-auto-commit-action@v5.0.0
28+
with:
29+
commit_message: "Format code with isort and black"
30+
pre-commit:
31+
runs-on: ubuntu-latest
32+
steps:
33+
- uses: actions/checkout@v4.1.1
34+
- uses: actions/setup-python@v5.0.0
35+
- uses: pre-commit/action@v3.0.0
36+
Pylint:
37+
runs-on: ubuntu-latest
38+
strategy:
39+
fail-fast: false
40+
matrix:
41+
python-version: ["3.10"]
42+
steps:
43+
- uses: actions/checkout@v4.1.1
44+
- name: Set up Python ${{ matrix.python-version }}
45+
uses: actions/setup-python@v5.0.0
46+
with:
47+
python-version: ${{ matrix.python-version }}
48+
- name: Install dependencies
49+
run: |
50+
python -m pip install --upgrade pip
51+
pip install -r requirements.txt
52+
- name: Analysing the code with pylint
53+
run: |
54+
pylint $(git ls-files '*.py') --rcfile=$(git ls-files '.pylintrc')

.github/workflows/pre-commit.yml

Lines changed: 0 additions & 16 deletions
This file was deleted.

.github/workflows/pylint.yml

Lines changed: 0 additions & 26 deletions
This file was deleted.

0 commit comments

Comments
 (0)