mirror of
https://github.com/natelandau/shell-scripting-templates.git
synced 2025-11-17 09:23:39 -05:00
updates: - [github.com/commitizen-tools/commitizen: v3.13.0 → v4.1.0](https://github.com/commitizen-tools/commitizen/compare/v3.13.0...v4.1.0) - [github.com/pre-commit/pre-commit-hooks: v4.5.0 → v5.0.0](https://github.com/pre-commit/pre-commit-hooks/compare/v4.5.0...v5.0.0) - [github.com/adrienverge/yamllint.git: v1.33.0 → v1.35.1](https://github.com/adrienverge/yamllint.git/compare/v1.33.0...v1.35.1) - [github.com/crate-ci/typos: v1.16.26 → v1.28.3](https://github.com/crate-ci/typos/compare/v1.16.26...v1.28.3)
81 lines
2.4 KiB
YAML
81 lines
2.4 KiB
YAML
---
|
|
# See https://pre-commit.com for more information
|
|
# See https://pre-commit.com/hooks.html for more hooks
|
|
|
|
default_install_hook_types: [commit-msg, pre-commit]
|
|
default_stages: [pre-commit, manual]
|
|
fail_fast: true
|
|
repos:
|
|
- repo: "https://github.com/commitizen-tools/commitizen"
|
|
rev: v4.1.0
|
|
hooks:
|
|
- id: commitizen
|
|
- id: commitizen-branch
|
|
stages:
|
|
- post-commit
|
|
- pre-push
|
|
- repo: "https://github.com/pre-commit/pre-commit-hooks"
|
|
rev: v5.0.0
|
|
hooks:
|
|
- id: check-added-large-files
|
|
- id: check-byte-order-marker
|
|
- id: check-case-conflict
|
|
- id: check-executables-have-shebangs
|
|
- id: check-json
|
|
- id: check-merge-conflict
|
|
- id: check-shebang-scripts-are-executable
|
|
exclude: '\.sed$'
|
|
- id: check-symlinks
|
|
- id: check-xml
|
|
- id: check-yaml
|
|
- id: destroyed-symlinks
|
|
- id: detect-aws-credentials
|
|
- id: detect-private-key
|
|
- id: end-of-file-fixer
|
|
- id: fix-byte-order-marker
|
|
- id: mixed-line-ending
|
|
- id: trailing-whitespace
|
|
|
|
- repo: "https://github.com/adrienverge/yamllint.git"
|
|
rev: v1.35.1
|
|
hooks:
|
|
- id: yamllint
|
|
files: \.(yaml|yml)$
|
|
entry: yamllint --strict --config-file .yamllint.yml
|
|
|
|
- repo: "https://github.com/crate-ci/typos"
|
|
rev: v1.28.3
|
|
hooks:
|
|
- id: typos
|
|
|
|
- repo: local
|
|
hooks:
|
|
- id: poetry-check
|
|
name: poetry check
|
|
entry: poetry check
|
|
language: system
|
|
files: pyproject.toml
|
|
pass_filenames: false
|
|
|
|
# This calls a personal pre-commit script. Disable if you don't have it.
|
|
- id: stopwords
|
|
name: stopwords
|
|
entry: bash -c '~/bin/git-stopwords ${PWD}/"$@"'
|
|
language: system
|
|
pass_filenames: true
|
|
|
|
- id: bats
|
|
name: bats
|
|
language: system
|
|
files: '^test/.*\.bats$'
|
|
types_or: [shell, bash, sh, zsh]
|
|
entry: bash -c 'find test/ -maxdepth 1 -name "*.bats" -print0 | xargs -0 -n1 bats -t'
|
|
pass_filenames: false
|
|
|
|
- id: shellcheck
|
|
name: shellcheck
|
|
entry: shellcheck
|
|
language: system
|
|
types: [shell, bash, sh]
|
|
exclude: '^archive/.*|.*\.bats'
|