|
| 1 | +repos: |
| 2 | + - repo: https://github.com/pre-commit/pre-commit-hooks |
| 3 | + rev: v4.0.1 |
| 4 | + hooks: |
| 5 | + - id: check-added-large-files |
| 6 | + - id: fix-byte-order-marker |
| 7 | + - id: check-merge-conflict |
| 8 | + - id: trailing-whitespace |
| 9 | + exclude: (?x)( |
| 10 | + \.yarn/| |
| 11 | + spec/files/) |
| 12 | + |
| 13 | + - repo: https://github.com/tdeo/pre-commit-hooks |
| 14 | + rev: v4.0.1 |
| 15 | + hooks: |
| 16 | + - id: end-of-file-fixer |
| 17 | + exclude: spec/files/ |
| 18 | + - repo: https://github.com/shellcheck-py/shellcheck-py |
| 19 | + rev: v0.8.0.1 |
| 20 | + hooks: |
| 21 | + - id: shellcheck |
| 22 | + |
| 23 | + - repo: local |
| 24 | + hooks: |
| 25 | + - id: do_not_commit |
| 26 | + name: Break on DO NOT COMMIT comment |
| 27 | + language: pygrep |
| 28 | + entry: (?i)(NOT.{,3}COMMIT) |
| 29 | + exclude: (?x)( |
| 30 | + .pre-commit-config.yaml| |
| 31 | + README.md) |
| 32 | + - id: rubocop |
| 33 | + name: Rubocop |
| 34 | + language: system |
| 35 | + entry: bash -c 'bundle exec rubocop ${RUBOCOP_OPTIONS:---autocorrect} "$@"' -- |
| 36 | + require_serial: true # for proper cache behavior |
| 37 | + files: (?x)( |
| 38 | + \.(rb|rake|jbuilder|gemspec)$| |
| 39 | + Gemfile$| |
| 40 | + Rakefile| |
| 41 | + .irbrc$) |
| 42 | + args: |
| 43 | + - --color |
| 44 | + - --server |
| 45 | + - --config=.rubocop.yml |
| 46 | + - --fail-level=convention |
| 47 | + - id: ruboclean |
| 48 | + name: Ruboclean |
| 49 | + language: system |
| 50 | + entry: bundle exec ruboclean |
| 51 | + files: ^\.rubocop.*\.yml$ |
| 52 | + args: |
| 53 | + - --silent |
| 54 | + - --preserve-comments |
| 55 | + - id: ruby |
| 56 | + name: Valid ruby syntax |
| 57 | + language: system |
| 58 | + entry: ruby -c |
| 59 | + files: \.rb$ |
| 60 | + exclude: lib/templates/rspec/ |
| 61 | + - id: prettier-json |
| 62 | + name: Prettier JSON |
| 63 | + language: system |
| 64 | + entry: npx prettier --parser json --write |
| 65 | + files: \.json$ |
| 66 | + - id: prettier-yaml |
| 67 | + name: Prettier YAML |
| 68 | + language: system |
| 69 | + entry: npx prettier --parser yaml --write |
| 70 | + files: \.ya?ml$ |
| 71 | + exclude: ^\.rubocop\.yml |
| 72 | + - id: prettier-mdx |
| 73 | + name: Prettier MDX |
| 74 | + language: system |
| 75 | + entry: npx prettier --parser mdx --write |
| 76 | + files: \.mdx?$ |
| 77 | + - id: whitespaces |
| 78 | + name: No non-breaking spaces |
| 79 | + language: pygrep |
| 80 | + entry: \\u00A0 # Non-breaking space |
| 81 | + exclude: (?x)^( |
| 82 | + \.yarn/releases/| |
| 83 | + \.pre-commit-config\.yaml) |
| 84 | + - id: license_checks |
| 85 | + name: License checks |
| 86 | + language: system |
| 87 | + entry: .pre-commit/check_license.sh |
| 88 | + files: ^doc/dependency_decisions\.yml$ |
| 89 | + pass_filenames: false |
0 commit comments