Skip to content

Commit f7d2f7d

Browse files
authored
Merge pull request #75 from cadenmyers13/precommit-ci
Migrate to pre-commit ci
2 parents ea9df03 + ac45aa4 commit f7d2f7d

File tree

1 file changed

+15
-5
lines changed

1 file changed

+15
-5
lines changed

.pre-commit-config.yaml

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,22 @@
11
default_language_version:
22
python: python3
3+
ci:
4+
autofix_commit_msg: |
5+
[pre-commit.ci] auto fixes from pre-commit hooks
6+
autofix_prs: true
7+
autoupdate_branch: 'pre-commit-autoupdate'
8+
autoupdate_commit_msg: '[pre-commit.ci] pre-commit autoupdate'
9+
autoupdate_schedule: monthly
10+
skip: [no-commit-to-branch]
11+
submodules: false
312
repos:
413
- repo: https://github.com/pre-commit/pre-commit-hooks
514
rev: v4.4.0
615
hooks:
716
- id: check-yaml
817
- id: end-of-file-fixer
918
- id: trailing-whitespace
19+
exclude: '\.(rst|txt)$'
1020
- repo: https://github.com/ambv/black
1121
rev: 23.3.0
1222
hooks:
@@ -24,10 +34,10 @@ repos:
2434
rev: 0.6.1
2535
hooks:
2636
- id: nbstripout
27-
- repo: local
37+
- repo: https://github.com/pre-commit/pre-commit-hooks
38+
rev: v4.4.0
2839
hooks:
29-
- id: prevent-commit-to-main
40+
- id: no-commit-to-branch
3041
name: Prevent Commit to Main Branch
31-
entry: ./prevent_commit_to_main.sh
32-
language: script
33-
stages: [commit]
42+
args: ["--branch", "main"]
43+
stages: [pre-commit]

0 commit comments

Comments
 (0)