laconic-registry-cli/src/index.ts

30 lines
622 B
TypeScript
Raw Normal View History

2022-04-22 12:22:17 +00:00
import yargs from 'yargs/yargs';
import { hideBin } from 'yargs/helpers';
// eslint-disable-next-line no-unused-expressions
2022-04-22 12:22:17 +00:00
yargs(hideBin(process.argv))
.options({
verbose: {
description: 'Verbose output',
demand: false,
default: false,
type: 'boolean',
alias: 'v'
},
config: {
alias: 'c',
default: 'config.yml',
describe: 'Config file path.',
type: 'string'
2023-03-27 12:05:47 +00:00
},
output: {
alias: 'o',
describe: 'Gives output in json format when specified.',
type: 'string'
}
})
2022-04-22 12:22:17 +00:00
.commandDir('cmds')
.demandCommand()
.help()
.argv;