mirror of
https://github.com/sharkdp/bat.git
synced 2024-11-30 11:44:17 +01:00
Added new alias for 'decoration=always'
This commit is contained in:
parent
57a8122a6b
commit
565a80305c
@ -174,7 +174,8 @@ impl App {
|
|||||||
term_width: maybe_term_width.unwrap_or(Term::stdout().size().1 as usize),
|
term_width: maybe_term_width.unwrap_or(Term::stdout().size().1 as usize),
|
||||||
loop_through: !(self.interactive_output
|
loop_through: !(self.interactive_output
|
||||||
|| self.matches.value_of("color") == Some("always")
|
|| self.matches.value_of("color") == Some("always")
|
||||||
|| self.matches.value_of("decorations") == Some("always")),
|
|| (self.matches.value_of("decorations") == Some("always")
|
||||||
|
|| self.matches.is_present("always-decorations"))),
|
||||||
tab_width: self
|
tab_width: self
|
||||||
.matches
|
.matches
|
||||||
.value_of("tabs")
|
.value_of("tabs")
|
||||||
|
@ -257,6 +257,15 @@ pub fn build_app(interactive_output: bool) -> ClapApp<'static, 'static> {
|
|||||||
an interactive terminal is detected. Possible values: *auto*, never, always.",
|
an interactive terminal is detected. Possible values: *auto*, never, always.",
|
||||||
),
|
),
|
||||||
)
|
)
|
||||||
|
.arg(
|
||||||
|
Arg::with_name("always-decorations")
|
||||||
|
.short("D")
|
||||||
|
.alias("always-decor")
|
||||||
|
.overrides_with("always-decorations")
|
||||||
|
.hidden(true)
|
||||||
|
.hidden_short_help(true)
|
||||||
|
.help("Alias for '--decorations=always'")
|
||||||
|
)
|
||||||
.arg(
|
.arg(
|
||||||
Arg::with_name("paging")
|
Arg::with_name("paging")
|
||||||
.long("paging")
|
.long("paging")
|
||||||
|
Loading…
Reference in New Issue
Block a user