diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/configs/nix_shell.rs | 4 | ||||
-rw-r--r-- | src/modules/nix_shell.rs | 1 |
2 files changed, 4 insertions, 1 deletions
diff --git a/src/configs/nix_shell.rs b/src/configs/nix_shell.rs index d5316b6ae..214277fa3 100644 --- a/src/configs/nix_shell.rs +++ b/src/configs/nix_shell.rs @@ -9,6 +9,7 @@ pub struct NixShellConfig<'a> { pub impure_msg: SegmentConfig<'a>, pub pure_msg: SegmentConfig<'a>, pub style: Style, + pub symbol: SegmentConfig<'a>, pub disabled: bool, } @@ -18,7 +19,8 @@ impl<'a> RootModuleConfig<'a> for NixShellConfig<'a> { use_name: false, impure_msg: SegmentConfig::new("impure"), pure_msg: SegmentConfig::new("pure"), - style: Color::Red.bold(), + style: Color::Blue.bold(), + symbol: SegmentConfig::new("❄️ "), disabled: false, } } diff --git a/src/modules/nix_shell.rs b/src/modules/nix_shell.rs index 33fb5bb81..b174645d3 100644 --- a/src/modules/nix_shell.rs +++ b/src/modules/nix_shell.rs @@ -27,6 +27,7 @@ pub fn module<'a>(context: &'a Context) -> Option<Module<'a>> { let config: NixShellConfig = NixShellConfig::try_load(module.config); module.set_style(config.style); + module.create_segment("symbol", &config.symbol); let shell_type = env::var("IN_NIX_SHELL").ok()?; let shell_type_segment: SegmentConfig = match shell_type.as_ref() { |