From 4d8e4cdb078b379704cdc18b5278a7d32b1a681a Mon Sep 17 00:00:00 2001 From: Yechiel Worenklein <41305372+yechielw@users.noreply.github.com> Date: Tue, 19 Nov 2024 23:57:57 +0200 Subject: [PATCH] oh-my-posh: added option to supply config path --- modules/programs/oh-my-posh.nix | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/modules/programs/oh-my-posh.nix b/modules/programs/oh-my-posh.nix index 8c46a1c69..9dd62e9b1 100644 --- a/modules/programs/oh-my-posh.nix +++ b/modules/programs/oh-my-posh.nix @@ -11,6 +11,8 @@ let "--config ${config.xdg.configHome}/oh-my-posh/config.json" else if cfg.useTheme != null then "--config ${cfg.package}/share/oh-my-posh/themes/${cfg.useTheme}.omp.json" + else if cfg.configFile != null then + "--config ${cfg.configFile}" else ""; @@ -47,6 +49,14 @@ in { ''; }; + configFile = mkOption { + type = types.nullOr types.path; + default = null; + description = '' + Path to a custom configuration path, can be json, yaml or toml. + ''; + }; + enableBashIntegration = mkOption { type = types.bool; default = true;