diff --git a/{{cookiecutter.repo_name}}/.pre-commit-config.yaml b/{{cookiecutter.repo_name}}/.pre-commit-config.yaml index 8d779db8bd7cef2c1b0d01a7af35d12ecf39e0f8..f0e4e95e4cf1259b22ef874327e6de1891eb0940 100644 --- a/{{cookiecutter.repo_name}}/.pre-commit-config.yaml +++ b/{{cookiecutter.repo_name}}/.pre-commit-config.yaml @@ -1,25 +1,28 @@ repos: -- repo: https://github.com/pre-commit/pre-commit-hooks + - repo: https://github.com/pre-commit/pre-commit-hooks rev: v4.4.0 hooks: - - id: trailing-whitespace - - id: end-of-file-fixer - - id: check-docstring-first -- repo: https://github.com/pycqa/flake8 - rev: 6.0.0 + # - id: check-added-large-files # prevents giant files from being committed. + - id: check-case-conflict # checks for files that would conflict in case-insensitive filesystems. + - id: check-merge-conflict # checks for files that contain merge conflict strings. + - id: check-yaml # checks yaml files for parseable syntax. + - id: detect-private-key # detects the presence of private keys. + - id: end-of-file-fixer # ensures that a file is either empty, or ends with one newline. + - id: fix-byte-order-marker # removes utf-8 byte order marker. + - id: mixed-line-ending # replaces or checks mixed line ending. + - id: trailing-whitespace # trims trailing whitespace. + - repo: https://github.com/cheshirekow/cmake-format-precommit + rev: v0.6.13 hooks: - - id: flake8 -- repo: https://github.com/pycqa/isort - rev: 5.10.1 + - id: cmake-format + - repo: https://github.com/astral-sh/ruff-pre-commit + # Ruff version. + rev: v0.0.286 hooks: - - id: isort - name: isort (python) -- repo: https://github.com/ambv/black - rev: 22.10.0 + - id: ruff + args: [--fix, --exit-non-zero-on-fix] + types_or: [python, pyi, jupyter] + - repo: https://github.com/ambv/black + rev: 23.7.0 hooks: - - id: black -- repo: https://github.com/PyCQA/pylint - rev: v2.17.4 - hooks: - - id: pylint - args: [--disable=all, --enable=C0103, "--good-names=i,j,k,x,y,w,h,el,n"] \ No newline at end of file + - id: black