I have tried couple of ways for creating required command 'run' using CLI2
CommandBuider.. CLI2 not throws 'Missing required command run' with
Usage. Any other way to solve this problem ?
CommandBuilder cBuilder = new CommandBuilder();
GroupBuilder groupBuilder = new GroupBuilder();
Option testCmd;
testCmd =
cBuilder.withNmae("run").withDescription("RUN").withRequired(true).create();
Group finalGroup =
groupBuilder.withOption(testCmd)..withOption(testOption).withRequired(true).create();
(or)
CommandBuilder cBuilder = new CommandBuilder();
GroupBuilder groupBuilder = new GroupBuilder();
Option testCmd;
testCmd =
cBuilder.withNmae("run").withDescription("RUN").withRequired(true).create();
Group testCmdGroup =
groupBuilder.withMinimum(1).withMaximum(1).withOption(testCmd).withRequired(true).create();
Group finalGroup =
groupBuilder.withOption(testCmdGroup)..withOption(testOption).withRequired(true).create();