Skip to content

Commit

Permalink
Add .pre-commit-config.yaml
Browse files Browse the repository at this point in the history
  • Loading branch information
namurphy committed Mar 27, 2024
1 parent 455d488 commit 4388454
Showing 1 changed file with 69 additions and 0 deletions.
69 changes: 69 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
ci:
autofix_prs: false
autoupdate_schedule: monthly

# Specify the default version of Ruby in case it is not installed
default_language_version:
ruby: 2.7.2

repos:

- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.5.0
hooks:
- id: check-merge-conflict
name: check for git merge conflicts
exclude: .*\.rst
- id: check-case-conflict
name: check for filename case conflicts
- id: trailing-whitespace
- id: end-of-file-fixer
- id: check-json
- id: check-toml
- id: check-yaml

- repo: https://github.com/python-jsonschema/check-jsonschema
rev: 0.28.0
hooks:
- id: check-github-workflows

- repo: https://github.com/sirosen/texthooks
rev: 0.6.4
hooks:
- id: fix-smartquotes
- id: fix-spaces
- id: fix-ligatures
- id: forbid-bidi-controls

- repo: https://github.com/macisamuele/language-formatters-pre-commit-hooks
rev: v2.12.0
hooks:
- id: pretty-format-ini
args: [--autofix]
- id: pretty-format-yaml
args: [--autofix]
# For the labeler GitHub Action, labels with spaces in them must
# be put in quotes. However, the pretty-format-yaml hook will
# remove the quotes which will break that action, so we should not
# run this hook on `labeler.yml` (or certain other files).
exclude: .github/labeler.yml|.pre-commit-search-and-replace.yaml

- repo: https://github.com/mattlqx/pre-commit-search-and-replace
rev: v1.0.5
hooks:
- id: search-and-replace
exclude: changelog/.*|docs/changelog/.*|.sourcery.yaml|docs/_global_substitutions.py|CHANGELOG.rst

- repo: https://github.com/codespell-project/codespell
rev: v2.2.6
hooks:
- id: codespell
name: codespell (add false positives to pyproject.toml)
args: [--write-changes]
additional_dependencies:
- tomli

- repo: https://github.com/executablebooks/mdformat
rev: 0.7.17
hooks:
- id: mdformat

0 comments on commit 4388454

Please sign in to comment.