-
Notifications
You must be signed in to change notification settings - Fork 23
/
Copy path.cz-config.js
80 lines (72 loc) · 2.94 KB
/
.cz-config.js
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
79
80
module.exports = {
// Type definitions (selectable with up and down arrow keys)
types: [
{ value: 'feat', name: 'feat: New feature' },
{ value: 'fix', name: 'fix: Bug fix' },
{ value: 'docs', name: 'docs: Documentation changes' },
{ value: 'style', name: 'style: Code style (formatting, missing semicolons, etc.)' },
{ value: 'refactor', name: 'refactor: Code refactoring (no bug fixes or new features)' },
{ value: 'perf', name: 'perf: Performance improvements' },
{ value: 'test', name: 'test: Adding or modifying tests' },
{ value: 'build', name: 'build: Build process or external dependencies' },
{ value: 'ci', name: 'ci: Changes to CI configuration or scripts' },
{ value: 'chore', name: 'chore: Changes to the build process or auxiliary tools/libraries' },
{ value: 'revert', name: 'revert: Revert a previous commit' }
],
// Scope definitions (selectable with up and down arrow keys)
scopes: [
['components', 'Component related'],
['hooks', 'Hook related'],
['utils', 'Utility related'],
['element-ui', 'Changes to element-ui'],
['styles', 'Style related'],
['deps', 'Project dependencies'],
['auth', 'Changes to auth'],
['other', 'Other changes'],
// If selecting custom, it will prompt for a custom scope input. You can also skip this and set allowCustomScopes to true.
['custom', 'None of the above? I want to customize']
].map(([value, description]) => {
return {
value,
name: `${value.padEnd(30)} (${description})`
}
}),
// Allow custom scope input in addition to empty and custom options
// allowCustomScopes: true,
// allowTicketNumber: false,
// isTicketNumberRequired: false,
// ticketNumberPrefix: 'TICKET-',
// ticketNumberRegExp: '\\d{1,5}',
// Define scope overrides for each type, e.g. fix
/*
scopeOverrides: {
fix: [
{ name: 'merge' },
{ name: 'style' },
{ name: 'e2eTest' },
{ name: 'unitTest' }
]
},
*/
// Interactive prompt messages
messages: {
type: 'Ensure your commit follows the Angular convention!\nSelect the type of commit you are making:',
scope: '\nSelect a scope (optional):',
// Prompt when custom scope is selected
customScope: 'Enter a custom scope:',
subject: 'Write a short and concise change description:\n',
body: 'Write a more detailed change description (optional). Use "|" for new lines:\n',
breaking: 'List any breaking changes (optional):\n',
footer: 'List any issues closed by this change (optional). For example: #31, #34:\n',
confirmCommit: 'Confirm commit?'
},
// Only ask for breaking change if type is feat or fix
allowBreakingChanges: ['feat', 'fix'],
// Skip specific questions
// skipQuestions: ['body', 'footer'],
// Subject length limit
subjectLimit: 100,
breaklineChar: '|' // Support for body and footer
// footerPrefix : 'ISSUES CLOSED:'
// askForBreakingChangeFirst : true,
}