forked from numpy/numpydoc
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
57 lines (50 loc) · 1.74 KB
/
Copy path.pre-commit-config.yaml
File metadata and controls
57 lines (50 loc) · 1.74 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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
# Install pre-commit hooks via
# pre-commit install
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: f71fa2c1f9cf5cb705f73dffe4b21f7c61470ba9 # frozen: v4.4.0
hooks:
- id: trailing-whitespace
- id: end-of-file-fixer
- id: debug-statements
- id: check-ast
- id: mixed-line-ending
- id: check-yaml
args: [--allow-multiple-documents]
- id: check-json
- id: check-toml
- id: check-added-large-files
- repo: https://github.com/psf/black
rev: 193ee766ca496871f93621d6b58d57a6564ff81b # frozen: 23.7.0
hooks:
- id: black
- repo: https://github.com/pre-commit/mirrors-prettier
rev: 672abe14d309fc28817d45b6be25ea976a92222a # frozen: v3.0.2
hooks:
- id: prettier
files: \.(html|md|toml|yml|yaml)
args: [--prose-wrap=preserve]
- repo: https://github.com/adamchainz/blacken-docs
rev: 960ead214cd1184149d366c6d27ca6c369ce46b6 # frozen: 1.16.0
hooks:
- id: blacken-docs
- repo: https://github.com/asottile/pyupgrade
rev: b3e813e5d60a472ba815a45d107bbdf106405973 # frozen: v3.10.1
hooks:
- id: pyupgrade
args: [--py38-plus]
- repo: local
hooks:
- id: generate_requirements.py
name: generate_requirements.py
language: system
entry: python tools/generate_requirements.py
files: "pyproject.toml|requirements/.*\\.txt|tools/generate_requirements.py"
ci:
# This ensures that pr's aren't autofixed by the bot, rather you call
# the bot to make the fix
autofix_prs: false
autofix_commit_msg: |
'[pre-commit.ci 🤖] Apply code format tools to PR'
# Update hook versions every month (so we don't get hit with weekly update pr's)
autoupdate_schedule: monthly