-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy path.pre-commit-config.yaml
More file actions
78 lines (71 loc) · 1.97 KB
/
.pre-commit-config.yaml
File metadata and controls
78 lines (71 loc) · 1.97 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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
# 링크풀 (LinkPool) Pre-commit 설정
# https://pre-commit.com
#
# 설치 방법:
# pip install pre-commit
# pre-commit install
#
# 수동 실행:
# pre-commit run --all-files
default_language_version:
python: python3
repos:
# 일반적인 체크
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.5.0
hooks:
# 파일 끝에 빈 줄 추가
- id: end-of-file-fixer
exclude: '\.g\.dart$|\.freezed\.dart$'
# 줄 끝 공백 제거
- id: trailing-whitespace
exclude: '\.g\.dart$|\.freezed\.dart$'
# YAML 문법 검사
- id: check-yaml
# 큰 파일 추가 방지
- id: check-added-large-files
args: ['--maxkb=1000']
# 병합 충돌 마커 검사
- id: check-merge-conflict
# 비밀 키 검사
- id: detect-private-key
# JSON 문법 검사
- id: check-json
exclude: '\.vscode/'
# Flutter/Dart 전용 훅
- repo: local
hooks:
# Dart 포맷팅
- id: dart-format
name: Dart Format
entry: fvm dart format
language: system
types: [dart]
exclude: '\.g\.dart$|\.freezed\.dart$'
# Flutter 분석
- id: flutter-analyze
name: Flutter Analyze
entry: fvm flutter analyze --no-fatal-infos
language: system
types: [dart]
pass_filenames: false
# 테스트 실행 (선택적 - 느릴 수 있음)
# 주석 해제하여 활성화
# - id: flutter-test
# name: Flutter Test
# entry: fvm flutter test
# language: system
# types: [dart]
# pass_filenames: false
# stages: [push]
# Markdown 린트 (선택적)
- repo: https://github.com/igorshubovych/markdownlint-cli
rev: v0.38.0
hooks:
- id: markdownlint
args: ['--fix', '--disable', 'MD013', 'MD033', 'MD041', '--']
exclude: 'CHANGELOG\.md'
# CI 환경에서의 설정
ci:
autofix_prs: true
autoupdate_schedule: weekly