fn build_app() -> App<'static, 'static> {
  App::new(crate_name!())
    .about(crate_description!())
    .author(crate_authors!())
    .version(crate_version!())
    .template("{bin} {version}\nMade by {author}\n{about}\n\n{usage}\n\nFLAGS:\n{flags}")
    // Positional arguments:
    .arg(
      Arg::with_name("pattern")
          .required(true)
          .index(1)
    )
    .arg(
      Arg::with_name("files")
        .multiple(true)
        .default_value(STDIN)
        .index(2)
    )
    // Matching flags:
    .arg(
      Arg::with_name("invert-match")
        .short("v")
        .long("invert-match")
        .help("Invert the sense of matching, to select non matching slices")
    )
    .arg(
      Arg::with_name("ignore-case")
        .short("i")
        .long("ignore-case")
        .help("Case insensitive matching for ASCII alphabetic characters")
    )
    // Input flags:
    .arg(
      Arg::with_name("trim-ending-newline")
        .short("n")
        .long("trim-ending-newline")
        .help("If the file ends with a newline, disconsider the last byte")
    )
    // Output flags:
    .arg(
      Arg::with_name("with-filename")
        .short("H")
        .long("with-filename")
        .help("Print the file name for each match (default when there are multiple files).")
        .overrides_with("no-filename")
    )
    .arg(
      Arg::with_name("no-filename")
        .short("h")
        .long("no-filename")
        .help("Suppress the file names on output (default when there is a single file).")
        .overrides_with("with-filename")
        .conflicts_with_all(&[
          "files-with-matches",
          "files-without-matches",
        ])
    )
    .arg(
      Arg::with_name("only-matching")
        .short("o")
        .long("only-matching")
        .help("Prints the matched bytes of each match")
        .overrides_with_all(&[
          "byte-offset",
          "files-with-matches",
          "files-without-matches",
        ])
    )
    .arg(
      Arg::with_name("byte-offset")
        .short("b")
        .long("byte-offset")
        .help("Prints the byte offset of each match")
        .overrides_with_all(&[
          "only-matching",
          "files-with-matches",
          "files-without-matches",
        ])
    )
    .arg(
      Arg::with_name("files-with-matches")
        .short("l")
        .long("files-with-matches")
        .help("Prints the name of the matched files (default output mode)")
        .overrides_with_all(&[
          "only-matching",
          "byte-offset",
          "files-without-matches",
        ])
    )
    .arg(
      Arg::with_name("files-without-matches")
        .short("L")
        .long("files-without-matches")
        .help("Prints the name of non-matched files")
        .overrides_with_all(&[
          "only-matching",
          "byte-offset",
          "files-with-matches",
        ])
    )
}
/// Build clap's `App`. This specifies all arguments and metadata.
Build clap's `App`. This specifies all arguments and metadata.
Build clap ' s ` App ` . This specifies all arguments and metadata .
fn build_app() -> App<'static, 'static> {
  App::new(crate_name!())
    .about(crate_description!())
    .author(crate_authors!())
    .version(crate_version!())
    .template("{bin} {version}\nMade by {author}\n{about}\n\n{usage}\n\nFLAGS:\n{flags}")
    // Positional arguments:
    .arg(
      Arg::with_name("pattern")
          .required(true)
          .index(1)
    )
    .arg(
      Arg::with_name("files")
        .multiple(true)
        .default_value(STDIN)
        .index(2)
    )
    // Matching flags:
    .arg(
      Arg::with_name("invert-match")
        .short("v")
        .long("invert-match")
        .help("Invert the sense of matching, to select non matching slices")
    )
    .arg(
      Arg::with_name("ignore-case")
        .short("i")
        .long("ignore-case")
        .help("Case insensitive matching for ASCII alphabetic characters")
    )
    // Input flags:
    .arg(
      Arg::with_name("trim-ending-newline")
        .short("n")
        .long("trim-ending-newline")
        .help("If the file ends with a newline, disconsider the last byte")
    )
    // Output flags:
    .arg(
      Arg::with_name("with-filename")
        .short("H")
        .long("with-filename")
        .help("Print the file name for each match (default when there are multiple files).")
        .overrides_with("no-filename")
    )
    .arg(
      Arg::with_name("no-filename")
        .short("h")
        .long("no-filename")
        .help("Suppress the file names on output (default when there is a single file).")
        .overrides_with("with-filename")
        .conflicts_with_all(&[
          "files-with-matches",
          "files-without-matches",
        ])
    )
    .arg(
      Arg::with_name("only-matching")
        .short("o")
        .long("only-matching")
        .help("Prints the matched bytes of each match")
        .overrides_with_all(&[
          "byte-offset",
          "files-with-matches",
          "files-without-matches",
        ])
    )
    .arg(
      Arg::with_name("byte-offset")
        .short("b")
        .long("byte-offset")
        .help("Prints the byte offset of each match")
        .overrides_with_all(&[
          "only-matching",
          "files-with-matches",
          "files-without-matches",
        ])
    )
    .arg(
      Arg::with_name("files-with-matches")
        .short("l")
        .long("files-with-matches")
        .help("Prints the name of the matched files (default output mode)")
        .overrides_with_all(&[
          "only-matching",
          "byte-offset",
          "files-without-matches",
        ])
    )
    .arg(
      Arg::with_name("files-without-matches")
        .short("L")
        .long("files-without-matches")
        .help("Prints the name of non-matched files")
        .overrides_with_all(&[
          "only-matching",
          "byte-offset",
          "files-with-matches",
        ])
    )
}
fn build_app ( ) -> App < ' static , ' static > { App :: new ( crate_name ! ( ) ) . about ( crate_description ! ( ) ) . author ( crate_authors ! ( ) ) . version ( crate_version ! ( ) ) . template ( " \n \n \n \n \n \n \n " ) // Positional arguments: . arg ( Arg :: with_name ( " " ) . required ( true ) . index ( 1 ) ) . arg ( Arg :: with_name ( " " ) . multiple ( true ) . default_value ( STDIN ) . index ( 2 ) ) // Matching flags: . arg ( Arg :: with_name ( " " ) . short ( " " ) . long ( " " ) . help ( " " ) ) . arg ( Arg :: with_name ( " " ) . short ( " " ) . long ( " " ) . help ( " " ) ) // Input flags: . arg ( Arg :: with_name ( " " ) . short ( " " ) . long ( " " ) . help ( " " ) ) // Output flags: . arg ( Arg :: with_name ( " " ) . short ( " " ) . long ( " " ) . help ( " " ) . overrides_with ( " " ) ) . arg ( Arg :: with_name ( " " ) . short ( " " ) . long ( " " ) . help ( " " ) . overrides_with ( " " ) . conflicts_with_all ( & [ " " , " " , ] ) ) . arg ( Arg :: with_name ( " " ) . short ( " " ) . long ( " " ) . help ( " " ) . overrides_with_all ( & [ " " , " " , " " , ] ) ) . arg ( Arg :: with_name ( " " ) . short ( " " ) . long ( " " ) . help ( " " ) . overrides_with_all ( & [ " " , " " , " " , ] ) ) . arg ( Arg :: with_name ( " " ) . short ( " " ) . long ( " " ) . help ( " " ) . overrides_with_all ( & [ " " , " " , " " , ] ) ) . arg ( Arg :: with_name ( " " ) . short ( " " ) . long ( " " ) . help ( " " ) . overrides_with_all ( & [ " " , " " , " " , ] ) ) }
Build clap's `App`.
Build clap ' s ` App ` .