-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
config.ts
94 lines (84 loc) · 2.02 KB
/
config.ts
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
81
82
83
84
85
86
87
88
89
90
91
92
93
94
/**
* @file Interfaces - Config
* @module commitlint-config/interfaces/Config
*/
import type { ParserPreset } from '#src/types'
import type * as commitlint from '@commitlint/types'
import type PromptConfig from './config-prompt'
import type RulesConfig from './config-rules'
/**
* Object representing `commitlint` configuration for [Flex Development][1].
*
* [1]: https://flexdevelopment.llc
*
* @see https://commitlint.js.org/#/reference-configuration
*
* @extends {Required<Omit<commitlint.UserConfig,'extends'>>}
*/
interface Config extends Required<Omit<commitlint.UserConfig, 'extends'>> {
/**
* Use default ignore rules.
*
* @default true
*/
defaultIgnores: boolean
/**
* Report formatter.
*/
formatter: '@commitlint/format'
/**
* URL to show upon failure.
*
* @default 'https://github.com/conventional-changelog/commitlint/#what-is-commitlint'
*/
helpUrl: string
/**
* Functions that return `true` if `commitlint` should ignore the given
* message.
*
* @default []
*/
ignores: ((commit: string) => boolean)[]
/**
* Commit parser preset.
*
* @see {@linkcode ParserPreset}
*
* @default parserPreset
*/
parserPreset: ParserPreset
/**
* Plugins to apply.
*
* @see {@linkcode commitlint.Plugin}
* @see https://commitlint.js.org/#/reference-plugins
*
* @default []
*/
plugins: (commitlint.Plugin | string)[]
/**
* Prompt configuration used by [`@commitlint/cz-commitlint`][1].
*
* [1]: https://github.com/conventional-changelog/commitlint/tree/master/%40commitlint/cz-commitlint
*
* @see {@linkcode PromptConfig}
* @see https://commitlint.js.org/#/reference-prompt
*
* @default prompt
*/
prompt: PromptConfig
/**
* Commit rules.
*
* Enforces [conventional commits][1].
*
* [1]: https://www.conventionalcommits.org
*
* @see {@linkcode RulesConfig}
* @see https://commitlint.js.org/#/reference-rules
*
* @default rules
*/
rules: RulesConfig
}
export type { Config as default }