summaryrefslogtreecommitdiffstats
path: root/src/configs/starship_root.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/configs/starship_root.rs')
-rw-r--r--src/configs/starship_root.rs8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/configs/starship_root.rs b/src/configs/starship_root.rs
index 8edbbad44..aeb03358a 100644
--- a/src/configs/starship_root.rs
+++ b/src/configs/starship_root.rs
@@ -1,4 +1,5 @@
use serde::{Deserialize, Serialize};
+use std::collections::HashMap;
#[derive(Clone, Serialize, Deserialize, Debug)]
#[cfg_attr(
@@ -16,8 +17,13 @@ pub struct StarshipRootConfig {
pub scan_timeout: u64,
pub command_timeout: u64,
pub add_newline: bool,
+ #[serde(skip_serializing_if = "Option::is_none")]
+ pub palette: Option<String>,
+ pub palettes: HashMap<String, Palette>,
}
+pub type Palette = HashMap<String, String>;
+
// List of default prompt order
// NOTE: If this const value is changed then Default prompt order subheading inside
// prompt heading of config docs needs to be updated according to changes made here.
@@ -114,6 +120,8 @@ impl Default for StarshipRootConfig {
scan_timeout: 30,
command_timeout: 500,
add_newline: true,
+ palette: None,
+ palettes: HashMap::default(),
}
}
}