diff options
Diffstat (limited to 'zellij-utils/src/input/config.rs')
-rw-r--r-- | zellij-utils/src/input/config.rs | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/zellij-utils/src/input/config.rs b/zellij-utils/src/input/config.rs index 23c05d4f8..eb8fe521d 100644 --- a/zellij-utils/src/input/config.rs +++ b/zellij-utils/src/input/config.rs @@ -222,6 +222,15 @@ impl Config { Err(e) => Err(ConfigError::IoPath(e, path.into())), } } + pub fn merge(&mut self, other: Config) -> Result<(), ConfigError> { + self.options = self.options.merge(other.options); + self.keybinds.merge(other.keybinds.clone()); + self.themes = self.themes.merge(other.themes); + self.plugins = self.plugins.merge(other.plugins); + self.ui = self.ui.merge(other.ui); + self.env = self.env.merge(other.env); + Ok(()) + } } #[cfg(test)] |