-
Notifications
You must be signed in to change notification settings - Fork 2
/
.pre-commit-config.yaml
43 lines (41 loc) · 1.2 KB
/
.pre-commit-config.yaml
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
# Copyright (C) 2024 Roberto Rossini <roberros@uio.no>
#
# SPDX-License-Identifier: MIT
default_language_version:
python: python3 # Defaults to python2, so override it.
exclude: ^data
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
hooks:
- id: check-added-large-files
- id: check-case-conflict
- id: check-shebang-scripts-are-executable
- id: check-symlinks
- id: check-yaml
- id: end-of-file-fixer
- id: forbid-submodules
- id: mixed-line-ending
args:
- --fix=lf
- id: trailing-whitespace
# Formatters should be run late so that they can re-format any prior changes.
- repo: https://github.com/kynan/nbstripout
rev: 0.8.1
hooks:
- id: nbstripout
- repo: https://github.com/psf/black-pre-commit-mirror
rev: 24.10.0
hooks:
- id: black-jupyter
args: ["--line-length", "120", "--target-version", "py39"]
- repo: https://github.com/pycqa/isort
rev: 5.13.2
hooks:
- id: isort
args: ["--profile", "black", "--py", "39"]
- repo: https://github.com/pre-commit/mirrors-prettier
rev: v3.1.0
hooks:
- id: prettier
types_or: [markdown, yaml]