Skip to content

Commit

Permalink
Merge pull request #1290 from girder/add-pre-commit-config
Browse files Browse the repository at this point in the history
Add pre-commit-config file for developer convenience
  • Loading branch information
manthey authored Sep 1, 2023
2 parents 79a8839 + c113d8c commit 6efc4a6
Show file tree
Hide file tree
Showing 2 changed files with 90 additions and 1 deletion.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,6 @@ test/externaldata
docs/source/*
!docs/source/*.py
!docs/source/*.rst
.pre-commit-config.yaml

*.ipynb
!docs/*.ipynb
Expand Down
90 changes: 90 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,90 @@
# Initially run
# pre-commit install
# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
hooks:
- id: check-added-large-files
- id: check-ast
- id: check-builtin-literals
- id: check-case-conflict
- id: check-docstring-first
- id: check-executables-have-shebangs
- id: check-json
- id: check-merge-conflict
- id: check-shebang-scripts-are-executable
# - id: check-symlinks
# - id: check-toml
# - id: check-xml
- id: check-yaml
- id: debug-statements
- id: destroyed-symlinks
- id: detect-private-key
- id: double-quote-string-fixer
- id: end-of-file-fixer
- id: fix-byte-order-marker
- id: forbid-new-submodules
- id: mixed-line-ending
- id: trailing-whitespace
- repo: https://github.com/pre-commit/pygrep-hooks
rev: v1.10.0
hooks:
- id: python-no-eval
- id: python-no-log-warn
- id: rst-backticks
- id: rst-directive-colons
- id: rst-inline-touching-normal
- id: text-unicode-replacement-char
- repo: https://github.com/Lucas-C/pre-commit-hooks-markup
rev: v1.0.1
hooks:
- id: rst-linter
files: README.rst
name: rst-linter of README.rst
- repo: https://github.com/codespell-project/codespell
rev: v2.2.5
hooks:
- id: codespell
args:
- --ignore-words-list
- "hist,indext,pixelx,thex,subtile,slippy"
- repo: https://github.com/syntaqx/git-hooks
rev: v0.0.18
hooks:
- id: circleci-config-validate
- repo: https://github.com/ThisIsManta/stylus-supremacy
rev: v2.17.5
hooks:
- id: stylus-supremacy
args:
- '--options'
- './girder/girder_large_image/web_client/package.json'
- repo: https://github.com/asottile/pyupgrade
rev: v3.10.1
hooks:
- id: pyupgrade
args:
- --py36-plus
- --keep-percent-format
- repo: https://github.com/astral-sh/ruff-pre-commit
# Ruff version.
rev: v0.0.286
hooks:
- id: ruff
args: [--fix, --exit-non-zero-on-fix]
types_or: [python, pyi, jupyter]
- repo: https://github.com/pre-commit/mirrors-autopep8
rev: v2.0.4
hooks:
- id: autopep8
- repo: https://github.com/PyCQA/flake8
rev: 6.1.0
hooks:
- id: flake8
- repo: https://github.com/pycqa/isort
rev: 5.12.0
hooks:
- id: isort
name: isort (python)

0 comments on commit 6efc4a6

Please sign in to comment.