mirror of
https://github.com/sharkdp/bat
synced 2024-11-18 15:26:16 +00:00
Merge remote-tracking branch 'origin/master' into fix-1063
This commit is contained in:
commit
552545fe5f
@ -10,6 +10,7 @@
|
|||||||
- Only print themes hint in interactive mode (`bat --list-themes`), see #1439 (@rsteube)
|
- Only print themes hint in interactive mode (`bat --list-themes`), see #1439 (@rsteube)
|
||||||
- Make ./tests/syntax-tests/regression_test.sh work on recent versions of macOS, see #1443 (@Enselic)
|
- Make ./tests/syntax-tests/regression_test.sh work on recent versions of macOS, see #1443 (@Enselic)
|
||||||
- VimL syntax highlighting fix, see #1450 (@esensar)
|
- VimL syntax highlighting fix, see #1450 (@esensar)
|
||||||
|
- Print an 'Invalid syntax theme settings' error message if a custom theme is broken, see #614 (@Enselic)
|
||||||
- Ignore PAGER=most with a warning to stderr, but allow override with BAT_PAGER or --config, see #1063 (@Enselic)
|
- Ignore PAGER=most with a warning to stderr, but allow override with BAT_PAGER or --config, see #1063 (@Enselic)
|
||||||
|
|
||||||
## Other
|
## Other
|
||||||
|
@ -38,9 +38,16 @@ impl HighlightingAssets {
|
|||||||
};
|
};
|
||||||
|
|
||||||
let theme_dir = source_dir.join("themes");
|
let theme_dir = source_dir.join("themes");
|
||||||
|
if theme_dir.exists() {
|
||||||
let res = theme_set.add_from_folder(&theme_dir);
|
let res = theme_set.add_from_folder(&theme_dir);
|
||||||
if res.is_err() {
|
if let Err(err) = res {
|
||||||
|
println!(
|
||||||
|
"Failed to load one or more themes from '{}' (reason: '{}')",
|
||||||
|
theme_dir.to_string_lossy(),
|
||||||
|
err,
|
||||||
|
);
|
||||||
|
}
|
||||||
|
} else {
|
||||||
println!(
|
println!(
|
||||||
"No themes were found in '{}', using the default set",
|
"No themes were found in '{}', using the default set",
|
||||||
theme_dir.to_string_lossy()
|
theme_dir.to_string_lossy()
|
||||||
|
Loading…
Reference in New Issue
Block a user