mirror of
https://github.com/sharkdp/bat.git
synced 2026-10-26 20:16:33 +00:00
only print themes hint in interactive mode
This commit is contained in:
1 parent
f3489ffa29
commit
84b0702399
2 files changed
+7
-5
No files matched your search
@@ -5,6 +5,8 @@
|
||||
|
||||
## Bugfixes
|
||||
|
||||
- only print themes hint in interactive mode (`bat --list-themes`), see #1439 (@rsteube)
|
||||
|
||||
## Other
|
||||
|
||||
## Syntaxes
|
||||
|
||||
+5
-5
@@ -200,11 +200,6 @@ pub fn list_themes(cfg: &Config) -> Result<()> {
|
||||
.ok();
|
||||
writeln!(stdout)?;
|
||||
}
|
||||
} else {
|
||||
for theme in assets.themes() {
|
||||
writeln!(stdout, "{}", theme)?;
|
||||
}
|
||||
}
|
||||
writeln!(
|
||||
stdout,
|
||||
"Further themes can be installed to '{}', \
|
||||
@@ -213,6 +208,11 @@ pub fn list_themes(cfg: &Config) -> Result<()> {
|
||||
https://github.com/sharkdp/bat#adding-new-themes",
|
||||
config_file().join("themes").to_string_lossy()
|
||||
)?;
|
||||
} else {
|
||||
for theme in assets.themes() {
|
||||
writeln!(stdout, "{}", theme)?;
|
||||
}
|
||||
}
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user