notebook/.pre-commit-config.yaml

82 lines
2.1 KiB
YAML
Raw Normal View History

2022-04-01 21:48:40 +08:00
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.3.0
2022-04-01 21:48:40 +08:00
hooks:
- id: forbid-new-submodules
2022-04-02 00:02:12 +08:00
- id: end-of-file-fixer
- id: check-case-conflict
- id: check-executables-have-shebangs
- id: requirements-txt-fixer
- id: check-added-large-files
- id: check-case-conflict
- id: check-toml
- id: check-yaml
- id: debug-statements
- id: check-builtin-literals
- id: trailing-whitespace
exclude: .bumpversion.cfg
2022-04-01 21:48:40 +08:00
2022-04-02 00:02:12 +08:00
- repo: https://github.com/psf/black
rev: 22.10.0
2022-04-02 00:02:12 +08:00
hooks:
- id: black
args: ["--line-length", "100"]
2022-04-01 21:48:40 +08:00
2022-04-02 00:02:12 +08:00
- repo: https://github.com/PyCQA/isort
rev: 5.10.1
hooks:
- id: isort
files: \.py$
args: [--profile=black]
2022-04-01 21:48:40 +08:00
2022-04-09 18:46:04 +08:00
- repo: https://github.com/PyCQA/doc8
rev: v1.0.0
2022-04-09 18:46:04 +08:00
hooks:
- id: doc8
args: [--max-line-length=200]
stages: [manual]
2022-10-17 08:28:25 +08:00
- repo: https://github.com/abravalheri/validate-pyproject
rev: v0.10.1
hooks:
- id: validate-pyproject
stages: [manual]
- repo: https://github.com/executablebooks/mdformat
rev: 0.7.16
hooks:
2022-10-17 08:28:25 +08:00
- id: mdformat
- repo: https://github.com/john-hen/Flake8-pyproject
rev: 1.1.0.post0
2022-10-17 08:28:25 +08:00
hooks:
- id: Flake8-pyproject
alias: flake8
additional_dependencies:
2022-10-17 08:28:25 +08:00
["flake8-bugbear==22.6.22", "flake8-implicit-str-concat==0.2.0"]
2022-04-09 18:46:04 +08:00
stages: [manual]
2022-04-01 21:48:40 +08:00
- repo: https://github.com/sirosen/check-jsonschema
rev: 0.19.1
2022-04-01 21:48:40 +08:00
hooks:
- id: check-jsonschema
name: 'Check GitHub Workflows'
files: ^\.github/workflows/
types: [yaml]
args: ['--schemafile', 'https://json.schemastore.org/github-workflow']
2022-04-09 18:46:04 +08:00
stages: [manual]
2022-04-01 21:48:40 +08:00
- repo: local
hooks:
- id: prettier
name: prettier
entry: 'npm run prettier:files'
language: node
2022-10-17 08:28:25 +08:00
types_or: [json, ts, tsx, javascript, jsx, css]
stages: [manual]
2022-04-01 21:48:40 +08:00
- id: integrity
name: integrity
entry: 'npm run integrity --force'
language: node
stages: [push]