Loading lib_util/cmdln_parser.c +22 −4 Original line number Diff line number Diff line Loading @@ -442,10 +442,6 @@ static void printUsage( const OptionProps *optionProps, const int32_t numOptions ) { fprintf( stderr, "\n" ); fprintf( stderr, "Usage: %s [options]\n", getBasename( argv0 ) ); fprintf( stderr, "\n" ); int32_t numOptChars; int32_t maxNumOptChars = 0; bool hasMandatoryOptions = false; Loading @@ -465,6 +461,28 @@ static void printUsage( } } fprintf( stderr, "\n" ); fprintf( stderr, "Usage: %s [options]", getBasename( argv0 ) ); for ( int32_t i = 0; i < numOptions; ++i ) { OptionProps opt = optionProps[i]; if ( opt.isMandatory ) { if (!isEmptyString(opt.matchShort)) { fprintf( stderr, " -%s", opt.matchShort ); } if ( !isEmptyString( opt.placeholder ) ) { fprintf( stderr, " %s", opt.placeholder ); } } } fprintf( stderr, "\n\n" ); if ( hasMandatoryOptions ) { fprintf( stderr, "Mandatory parameters:\n---------------------\n" ); Loading Loading
lib_util/cmdln_parser.c +22 −4 Original line number Diff line number Diff line Loading @@ -442,10 +442,6 @@ static void printUsage( const OptionProps *optionProps, const int32_t numOptions ) { fprintf( stderr, "\n" ); fprintf( stderr, "Usage: %s [options]\n", getBasename( argv0 ) ); fprintf( stderr, "\n" ); int32_t numOptChars; int32_t maxNumOptChars = 0; bool hasMandatoryOptions = false; Loading @@ -465,6 +461,28 @@ static void printUsage( } } fprintf( stderr, "\n" ); fprintf( stderr, "Usage: %s [options]", getBasename( argv0 ) ); for ( int32_t i = 0; i < numOptions; ++i ) { OptionProps opt = optionProps[i]; if ( opt.isMandatory ) { if (!isEmptyString(opt.matchShort)) { fprintf( stderr, " -%s", opt.matchShort ); } if ( !isEmptyString( opt.placeholder ) ) { fprintf( stderr, " %s", opt.placeholder ); } } } fprintf( stderr, "\n\n" ); if ( hasMandatoryOptions ) { fprintf( stderr, "Mandatory parameters:\n---------------------\n" ); Loading