Skip to content

Commit 4246081

Browse files
committed
chore: rollback some unnecessary changes
1 parent db186dd commit 4246081

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

@commitlint/cli/src/cli.ts

+6-6
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ const cli = yargs
5757
description: 'array of shareable configurations to extend',
5858
type: 'array'
5959
},
60-
helpUrl: {
60+
'help-url': {
6161
alias: 'H',
6262
type: 'string',
6363
description: 'helpurl in error message'
@@ -73,7 +73,7 @@ const cli = yargs
7373
description: 'output format of the results',
7474
type: 'string'
7575
},
76-
parserPreset: {
76+
'parser-preset': {
7777
alias: 'p',
7878
description:
7979
'configuration preset to use for conventional-commits-parser',
@@ -232,8 +232,8 @@ async function main(options: CliFlags) {
232232
const output = format(report, {
233233
color: flags.color,
234234
verbose: flags.verbose,
235-
helpUrl: flags.helpUrl
236-
? flags.helpUrl.trim()
235+
helpUrl: flags['help-url']
236+
? flags['help-url'].trim()
237237
: 'https://github.com/conventional-changelog/commitlint/#what-is-commitlint'
238238
});
239239

@@ -323,8 +323,8 @@ function getSeed(flags: CliFlags): Seed {
323323
(i): i is string => typeof i === 'string'
324324
);
325325
return n.length > 0
326-
? {extends: n, parserPreset: flags.parserPreset}
327-
: {parserPreset: flags.parserPreset};
326+
? {extends: n, parserPreset: flags['parser-preset']}
327+
: {parserPreset: flags['parser-preset']};
328328
}
329329

330330
function selectParserOpts(parserPreset: ParserPreset) {

@commitlint/cli/src/types.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,10 @@ export interface CliFlags {
66
env?: string;
77
extends?: (string | number)[];
88
help?: boolean;
9-
helpUrl?: string;
9+
'help-url'?: string;
1010
from?: string;
1111
format?: string;
12-
parserPreset?: string;
12+
'parser-preset'?: string;
1313
quiet: boolean;
1414
to?: string;
1515
version?: boolean;

0 commit comments

Comments
 (0)