Showing args in usage line with Clap

use clap::{AppSettings, Arg, Command};

fn main() {
    let _matches = Command::new("Test")
        .version("0.1")
        .arg(Arg::new("command"))
        .arg(Arg::new("filename"))
        .arg_required_else_help(true)
        .setting(AppSettings::DeriveDisplayOrder)
        .get_matches();
}

This shows:

Test 0.1

USAGE:
    playground [ARGS]

ARGS:
    <command>     
    <filename>  

But what I'd like to see is:

USAGE:
    playground <command> <filename>

Use help_template.

This topic was automatically closed 90 days after the last reply. We invite you to open a new topic if you have further questions or comments.