https://github.com/zerothi/sisl
Raw File
Tip revision: 1f429c39e03dc0b4882d77a9aaea27a15de0ba68 authored by Nick Papior on 04 April 2024, 18:10:25 UTC
small refactor of in [ to in (
Tip revision: 1f429c3
.pre-commit-config.yaml
# This config is used by pre-commit to run hooks on files before committing them to git
# To use it install pre-commit with:
#     `pip install pre-commit`
# and run
#     `pre-commit install`
# in the root of the repository
# From that point onwards, pre-commit will run the hooks on every commit.
# If pre-commit does some modification, the commit will fail. Add the
# changes done by pre-commit and commit again.
repos:
-   repo: https://github.com/pre-commit/pre-commit-hooks
    rev: v4.5.0
    hooks:
    -   id: check-yaml
    -   id: end-of-file-fixer
    -   id: trailing-whitespace
# Black to format code with a consistent style
- repo: https://github.com/psf/black-pre-commit-mirror
  rev: 24.2.0
  hooks:
    - id: black-jupyter
# isort to automatically sort imports
- repo: https://github.com/pycqa/isort
  rev: 5.12.0
  hooks:
    - id: isort
      name: isort (python)
# jupyter notebook cleans
- repo: local
  hooks:
    - id: jupyter-nb-clear-output
      name: jupyter-nb-clear-output
      files: \.ipynb$
      stages: [commit]
      language: system
      entry: jupyter nbconvert --ClearOutputPreprocessor.enabled=True --inplace
#License header
- repo: https://github.com/Lucas-C/pre-commit-hooks
  rev: v1.5.5
  hooks:
    - id: insert-license
      files: \.py$
      args:
        - --license-filepath
        - .LICENSE_header
        - --no-extra-eol
back to top