Skip to content

Commit

Permalink
Update .pre-commit-config.yaml
Browse files Browse the repository at this point in the history
  • Loading branch information
aniketmaurya authored Nov 17, 2024
1 parent 38196a3 commit fa41de5
Showing 1 changed file with 29 additions and 52 deletions.
81 changes: 29 additions & 52 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,76 +1,53 @@
# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
default_language_version:
python: python3.9
python: python3

ci:
autofix_prs: true
autoupdate_commit_msg: '[pre-commit.ci] pre-commit suggestions'
autoupdate_schedule: quarterly
autoupdate_commit_msg: "[pre-commit.ci] pre-commit suggestions"
autoupdate_schedule: "monthly"
# submodules: true

repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.5.0
rev: v5.0.0
hooks:
- id: end-of-file-fixer
- id: trailing-whitespace
exclude: '.*\.md$'
- id: check-case-conflict
- id: check-yaml
- id: check-docstring-first
- id: check-toml
- id: check-case-conflict
- id: check-json
- id: check-added-large-files
- id: check-docstring-first
- id: detect-private-key

- repo: https://github.com/psf/black
rev: 23.12.1
hooks:
- id: black
name: "Black: The uncompromising Python code formatter"

- repo: https://github.com/PyCQA/isort
rev: 5.13.2
hooks:
- id: isort
name: "Sort Imports"
args: [ "--profile black" ]

- repo: https://github.com/codespell-project/codespell
rev: v2.2.6
rev: v2.3.0
hooks:
- id: codespell
args:
- --ignore-words-list
- "ans,hist"
- --skip
- "*.bib,*.ipynb"

- repo: https://github.com/asottile/pyupgrade
rev: v3.15.0
hooks:
- id: pyupgrade
args: [ --py36-plus ]
additional_dependencies: [tomli]
#args: ["--write-changes"]

- repo: https://github.com/PyCQA/bandit
rev: 1.7.6
- repo: https://github.com/pre-commit/mirrors-prettier
rev: v3.1.0
hooks:
- id: bandit
language_version: python3
exclude: tests/
args:
- -s
- "B404,B602,B603,B607,B101"
- id: prettier
files: \.(json|yml|yaml|toml)
# https://prettier.io/docs/en/options.html#print-width
args: ["--print-width=120"]

- repo: local
- repo: https://github.com/PyCQA/docformatter
rev: 06907d0267368b49b9180eed423fae5697c1e909 # todo: fix for docformatter after last 1.7.5
hooks:
- id: clean
name: clean
entry: make
args: [ "clean" ]
language: system
pass_filenames: false
- id: docformatter
additional_dependencies: [tomli]
args: ["--in-place"]

- repo: https://github.com/kynan/nbstripout
rev: 0.6.1
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.7.2
hooks:
- id: nbstripout
args: [ "max-size 100k" ]
- id: ruff-format
args: ["--preview"]
- id: ruff
args: ["--fix"]

0 comments on commit fa41de5

Please sign in to comment.