Skip to content

Commit afd7cf3

Browse files
committed
Add pre-commit and flake8 configs
Signed-off-by: Eoin Fennessy <[email protected]>
1 parent 2efd57e commit afd7cf3

File tree

2 files changed

+31
-0
lines changed

2 files changed

+31
-0
lines changed

.flake8

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
[flake8]
2+
max-line-length = 100
3+
extend-ignore = W503

.pre-commit-config.yaml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
repos:
2+
- repo: https://github.com/pre-commit/pre-commit-hooks
3+
rev: v5.0.0
4+
hooks:
5+
- id: check-yaml
6+
args: [--allow-multiple-documents]
7+
- id: end-of-file-fixer
8+
- id: trailing-whitespace
9+
- repo: https://github.com/pycqa/isort
10+
rev: 6.0.1
11+
hooks:
12+
- id: isort
13+
name: isort
14+
entry: isort --profile black
15+
- repo: https://github.com/psf/black
16+
rev: 25.1.0
17+
hooks:
18+
- id: black
19+
- repo: https://github.com/pycqa/flake8
20+
rev: 7.2.0
21+
hooks:
22+
- id: flake8
23+
exclude: |
24+
(?x)^(
25+
kubeflow/trainer/__init__.py|
26+
kubeflow/trainer/api/__init__.py|
27+
kubeflow/trainer/models/.*|
28+
)$

0 commit comments

Comments
 (0)