Reproduction
All option names, aliases, handler flags, and handler paths must be unique within a command:
src/build.command.ts
import { CommandMajor, Container, Flag, Handler, Value } from 'func'
@CommandMajor()
class BuildCommand {
@Flag({ name: 'config' })
useConfig = false
@Value({ name: 'config' })
config = ''
@Handler()
run() {}
}
new Container([BuildCommand])How to fix it
Rename one conflicting token or remove the duplicate declaration:
src/build.command.ts
@CommandMajor()
class BuildCommand {
@Flag({ name: 'use-config' })
useConfig = false
@Value({ name: 'config' })
config = ''
@Handler()
run() {}
}
new Container([BuildCommand])