mirror of
https://github.com/sharkdp/bat.git
synced 2025-01-27 07:58:37 +01:00
Hide 'cache' subcommand, re-enable bold/underline styling, add note about cache subcommand
This commit is contained in:
parent
985666a390
commit
ccde13c9e8
@ -35,24 +35,6 @@ pub fn build_app(interactive_output: bool) -> Command {
|
||||
.max_term_width(100)
|
||||
.about("A cat(1) clone with wings.")
|
||||
.long_about("A cat(1) clone with syntax highlighting and Git integration.")
|
||||
// Force commands to go last
|
||||
.help_template(
|
||||
"\
|
||||
{before-help}{about-with-newline}
|
||||
{usage-heading} {usage}
|
||||
|
||||
Arguments:
|
||||
{positionals}
|
||||
|
||||
Options:
|
||||
{options}
|
||||
|
||||
Commands:
|
||||
{subcommands}{after-help}
|
||||
",
|
||||
)
|
||||
// Doesn't play well with `help_template`
|
||||
.disable_colored_help(true)
|
||||
.arg(
|
||||
Arg::new("FILE")
|
||||
.help("File(s) to print / concatenate. Use '-' for standard input.")
|
||||
@ -548,6 +530,7 @@ Commands:
|
||||
} else {
|
||||
app.subcommand(
|
||||
Command::new("cache")
|
||||
.hide(true)
|
||||
.about("Modify the syntax-definition and theme cache")
|
||||
.arg(
|
||||
Arg::new("build")
|
||||
@ -606,6 +589,10 @@ Commands:
|
||||
.help("Build acknowledgements.bin."),
|
||||
),
|
||||
)
|
||||
.after_long_help(
|
||||
"You can use 'bat cache' to customize syntaxes and themes. \
|
||||
See 'bat cache --help' for more information",
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user