-
-
Notifications
You must be signed in to change notification settings - Fork 5.7k
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
42 lines (39 loc) · 1.31 KB
/
.pre-commit-config.yaml
File metadata and controls
42 lines (39 loc) · 1.31 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
files: ^mlcourse_ai_jupyter_book/
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.0.1
hooks:
- id: check-added-large-files
args: ['--maxkb=1024']
- id: check-docstring-first
- id: check-json
- id: check-xml
- id: end-of-file-fixer
- id: trailing-whitespace
args: ["--markdown-linebreak-ext=md"]
# Add Ruff for lightning-fast linting and formatting (optional)
- repo: https://github.com/astral-sh/ruff-pre-commit
# Check for the latest tag on GitHub: https://github.com/astral-sh/ruff-pre-commit/releases
rev: v0.4.4
hooks:
# Run the linter.
- id: ruff
args: [--fix, --ignore, E722] # Add --fix to automatically fix issues
# Optional: Uncomment the line below to run the formatter instead of Black
# - id: ruff-format
- repo: https://github.com/pycqa/isort
rev: 5.13.2
hooks:
- id: isort
name: isort (python)
args: ["--profile", "black", "--filter-files"]
# Too much noise from Yaspeller (have to extend the dictionary too often),
# better to run manually from time to time
# `yaspeller -l en mlcourse_ai_jupyter_book/book/`
#
# - repo: https://github.com/hcodes/yaspeller.git
# rev: v8.0.0
# hooks:
# - id: yaspeller
# types: [markdown]
# files: \.md$