This repository has been archived by the owner on Apr 5, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 84
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
parse args and validate before any setup
Signed-off-by: Sally MacFarlane <[email protected]>
- Loading branch information
Showing
1 changed file
with
3 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -59,8 +59,10 @@ public boolean parseCommandLine(final String... args) { | |
} | ||
|
||
try { | ||
commandLine.parseWithHandlers(new RunLast().useOut(output), new ExceptionHandler<>(), args); | ||
// parseArgs ensures all args are populated and can then be validated prior to any setup | ||
commandLine.parseArgs(args); | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
usmansaleem
Contributor
|
||
baseCommand.validateOptions(commandLine, LOG); | ||
commandLine.parseWithHandlers(new RunLast().useOut(output), new ExceptionHandler<>(), args); | ||
return true; | ||
} catch (final ParameterException ex) { | ||
handleParameterException(ex); | ||
|
is that PicoCli officially mandated technique or is it adapted from Besu code?