2021-04-21 00:16:13 +08:00
|
|
|
default_stages: [commit]
|
2021-04-05 22:20:32 +08:00
|
|
|
repos:
|
|
|
|
- repo: https://github.com/pycqa/isort
|
2022-04-01 08:10:39 +08:00
|
|
|
rev: 5.10.1
|
2021-04-05 22:20:32 +08:00
|
|
|
hooks:
|
|
|
|
- id: isort
|
|
|
|
name: isort (python)
|
|
|
|
- id: isort
|
|
|
|
name: isort (cython)
|
|
|
|
types: [cython]
|
|
|
|
- id: isort
|
|
|
|
name: isort (pyi)
|
|
|
|
types: [pyi]
|
|
|
|
- repo: https://github.com/psf/black
|
2022-04-01 08:10:39 +08:00
|
|
|
rev: 22.3.0
|
2021-04-05 22:20:32 +08:00
|
|
|
hooks:
|
|
|
|
- id: black
|
|
|
|
- repo: https://gitlab.com/pycqa/flake8
|
2022-04-01 08:10:39 +08:00
|
|
|
rev: 4.0.1
|
2021-04-05 22:20:32 +08:00
|
|
|
hooks:
|
|
|
|
- id: flake8
|
2021-04-21 20:52:24 +08:00
|
|
|
additional_dependencies: [dlint]
|
2021-04-05 22:20:32 +08:00
|
|
|
- repo: https://github.com/pre-commit/pre-commit-hooks
|
2022-04-01 08:10:39 +08:00
|
|
|
rev: v4.1.0
|
2021-04-05 22:20:32 +08:00
|
|
|
hooks:
|
|
|
|
- id: check-added-large-files
|
|
|
|
- id: check-case-conflict
|
|
|
|
- id: check-json
|
|
|
|
- id: check-merge-conflict
|
|
|
|
- id: detect-private-key
|
|
|
|
- id: end-of-file-fixer
|
|
|
|
- id: trailing-whitespace
|
2021-04-12 20:15:52 +08:00
|
|
|
- repo: https://github.com/eslint/eslint
|
2022-04-01 08:10:39 +08:00
|
|
|
rev: v8.12.0
|
2021-04-12 20:15:52 +08:00
|
|
|
hooks:
|
|
|
|
- id: eslint
|
2021-04-15 18:41:09 +08:00
|
|
|
args: ["monkey/monkey_island/cc/ui/src/", "--fix", "--max-warnings=0"]
|
2022-08-25 23:15:21 +08:00
|
|
|
- repo: https://github.com/pre-commit/mirrors-mypy
|
|
|
|
rev: v0.971
|
|
|
|
hooks:
|
|
|
|
- id: mypy
|
|
|
|
additional_dependencies: [types-paramiko, types-python-dateutil, types-requests]
|
|
|
|
args: [--ignore-missing-imports]
|
2021-04-19 19:58:40 +08:00
|
|
|
- repo: local
|
|
|
|
hooks:
|
2021-04-23 15:48:11 +08:00
|
|
|
- id: pytest
|
2021-04-19 19:58:40 +08:00
|
|
|
name: pytest
|
|
|
|
entry: bash -c "cd monkey && pytest"
|
|
|
|
language: system
|
2021-04-20 02:57:40 +08:00
|
|
|
files: "monkey/"
|
|
|
|
exclude: "monkey/monkey_island/cc/ui"
|
2021-04-20 21:19:40 +08:00
|
|
|
stages: [push]
|
2021-04-26 18:40:36 +08:00
|
|
|
- repo: https://github.com/swimmio/pre-commit
|
2022-04-01 08:10:39 +08:00
|
|
|
rev: v0.7
|
2021-04-26 18:40:36 +08:00
|
|
|
hooks:
|
|
|
|
- id: swimm-verify
|
2021-05-04 00:42:41 +08:00
|
|
|
- repo: https://github.com/jendrikseipp/vulture
|
|
|
|
rev: v2.3
|
|
|
|
hooks:
|
|
|
|
- id: vulture
|