-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
44 lines (43 loc) · 1.63 KB
/
.pre-commit-config.yaml
File metadata and controls
44 lines (43 loc) · 1.63 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0
hooks:
- id: trailing-whitespace
description: "行末の空白を削除"
stages: [pre-commit, manual]
- id: end-of-file-fixer
description: "ファイルの末尾に改行を追加"
stages: [pre-commit, manual]
- id: check-yaml
description: "YAMLファイルのチェック"
stages: [pre-commit, manual]
- id: check-toml
description: "TOMLファイルのチェック"
stages: [pre-commit, manual]
- id: check-json
description: "JSONファイルのチェック"
stages: [pre-commit, manual]
- id: check-merge-conflict
description: "マージコンフリクトのチェック"
stages: [pre-push, manual]
- repo: local
hooks:
- id: mypy
name: mypy
entry: bash -c 'export UV_PROJECT=$(pwd)/packages/python/cli && uv sync --quiet && cd packages/python/cli && uv run mypy src/cli'
language: system
pass_filenames: false
files: ^packages/python/cli/
types_or: [python, pyi]
- id: ruff-check
name: ruff-check
entry: bash -c 'export UV_PROJECT=$(pwd)/packages/python/cli && uv sync --quiet && uv run ruff check --fix "$@"' --
language: system
files: ^packages/python/cli/
types_or: [python, pyi]
- id: ruff-format
name: ruff-format
entry: bash -c 'export UV_PROJECT=$(pwd)/packages/python/cli && uv sync --quiet && uv run ruff format "$@"' --
language: system
files: ^packages/python/cli/
types_or: [python, pyi]