Skip to content

Commit

Permalink
chore: rollback some unnecessary changes
Browse files Browse the repository at this point in the history
  • Loading branch information
armano2 committed Feb 11, 2020
1 parent db186dd commit 4246081
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
12 changes: 6 additions & 6 deletions @commitlint/cli/src/cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ const cli = yargs
description: 'array of shareable configurations to extend',
type: 'array'
},
helpUrl: {
'help-url': {
alias: 'H',
type: 'string',
description: 'helpurl in error message'
Expand All @@ -73,7 +73,7 @@ const cli = yargs
description: 'output format of the results',
type: 'string'
},
parserPreset: {
'parser-preset': {
alias: 'p',
description:
'configuration preset to use for conventional-commits-parser',
Expand Down Expand Up @@ -232,8 +232,8 @@ async function main(options: CliFlags) {
const output = format(report, {
color: flags.color,
verbose: flags.verbose,
helpUrl: flags.helpUrl
? flags.helpUrl.trim()
helpUrl: flags['help-url']
? flags['help-url'].trim()
: 'https://github.com/conventional-changelog/commitlint/#what-is-commitlint'
});

Expand Down Expand Up @@ -323,8 +323,8 @@ function getSeed(flags: CliFlags): Seed {
(i): i is string => typeof i === 'string'
);
return n.length > 0
? {extends: n, parserPreset: flags.parserPreset}
: {parserPreset: flags.parserPreset};
? {extends: n, parserPreset: flags['parser-preset']}
: {parserPreset: flags['parser-preset']};
}

function selectParserOpts(parserPreset: ParserPreset) {
Expand Down
4 changes: 2 additions & 2 deletions @commitlint/cli/src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ export interface CliFlags {
env?: string;
extends?: (string | number)[];
help?: boolean;
helpUrl?: string;
'help-url'?: string;
from?: string;
format?: string;
parserPreset?: string;
'parser-preset'?: string;
quiet: boolean;
to?: string;
version?: boolean;
Expand Down

0 comments on commit 4246081

Please sign in to comment.