a68b963388
This patch adds a readme describing how to add new queries or migrate existing sova regexes to the new queries format. It also updates the example query format. Change-Id: Ica6f90f42e98146200bcd0ffe78df4105b883938
47 lines
1.3 KiB
YAML
47 lines
1.3 KiB
YAML
---
|
|
repos:
|
|
- repo: https://github.com/pre-commit/pre-commit-hooks.git
|
|
rev: v3.4.0
|
|
hooks:
|
|
- id: end-of-file-fixer
|
|
- id: trailing-whitespace
|
|
- id: mixed-line-ending
|
|
- id: check-byte-order-marker
|
|
- id: check-executables-have-shebangs
|
|
- id: check-merge-conflict
|
|
- id: debug-statements
|
|
language_version: python3
|
|
- repo: https://github.com/adrienverge/yamllint.git
|
|
rev: v1.26.1
|
|
hooks:
|
|
- id: yamllint
|
|
files: \.(yaml|yml)$
|
|
types: [file, yaml]
|
|
entry: yamllint --strict
|
|
- id: yamllint
|
|
name: queries-key-ordering
|
|
files: src\/data\/queries\.yml$
|
|
entry: >
|
|
yamllint --strict -d "rules: { key-ordering: enable }"
|
|
- repo: https://github.com/pre-commit/mirrors-isort
|
|
rev: v5.8.0
|
|
hooks:
|
|
- id: isort
|
|
args:
|
|
# https://github.com/pre-commit/mirrors-isort/issues/9#issuecomment-624404082
|
|
- --filter-files
|
|
- repo: https://github.com/python/black.git
|
|
rev: 21.4b2
|
|
hooks:
|
|
- id: black
|
|
language_version: python3
|
|
- repo: https://github.com/pycqa/flake8.git
|
|
rev: 3.9.1
|
|
hooks:
|
|
- id: flake8
|
|
language_version: python3
|
|
additional_dependencies:
|
|
- flake8-2020>=1.6.0
|
|
- flake8-docstrings>=1.5.0
|
|
- flake8-pytest-style>=1.2.2
|