-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path.gitlab-analysis.example.yml
More file actions
70 lines (64 loc) · 1.74 KB
/
.gitlab-analysis.example.yml
File metadata and controls
70 lines (64 loc) · 1.74 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
# GitLab Release Analysis Configuration Example
# 複製此檔案為 .gitlab-analysis.yml 並修改以下設定
name: "your-project-name"
description: "Your project release configuration"
tag:
# 標籤匹配格式範例: v25.10.0, v25.10.5
# 請根據您的標籤格式修改正則表達式
pattern: "^v(\\d{2})\\.(\\d{1,2})\\.(\\d+)$"
groups:
year: 1 # 第一組:年份
month: 2 # 第二組:月份
patch: 3 # 第三組:patch 版本號
release_types:
# 主要發布版本(月度發布)
major:
name: "major"
description: "正式月度發布"
priority: 1
evaluate_batch_size: true # 評估批量健康度(月底集中合併反模式檢測)
rules:
- field: "patch"
operator: "equals"
value: 0
color: "green"
# 緊急修復版本
hotfix:
name: "hotfix"
description: "緊急修復版本"
priority: 2
evaluate_batch_size: false # 不評估批量(僅統計頻率作為品質指標)
rules:
- field: "patch"
operator: "ends_with"
value: 5
color: "red"
# 小版本更新
minor:
name: "minor"
description: "小版本更新"
priority: 99
evaluate_batch_size: false # 不評估批量(快速回應客戶需求,小批量是好事)
rules:
- field: "patch"
operator: "greater_than"
value: 0
color: "blue"
analysis:
default_branch: "main" # 或 "develop", "master"
thresholds:
mr_count:
healthy: 50
warning: 100
critical: 100
loc_changes:
healthy: 5000
warning: 10000
critical: 10000
release_interval_days:
expected: 30
tolerance: 5
code_freeze_days:
healthy_min: 1
healthy_max: 3
warning_max: 5