From 2fc1b9b5e00e31e23b015b2204840109f4e7fe55 Mon Sep 17 00:00:00 2001 From: Robert Helgesson Date: Thu, 4 Jan 2018 12:22:35 +0100 Subject: [PATCH] zsh: use shell library --- modules/programs/zsh.nix | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/modules/programs/zsh.nix b/modules/programs/zsh.nix index a088b332a..39203612b 100644 --- a/modules/programs/zsh.nix +++ b/modules/programs/zsh.nix @@ -11,17 +11,11 @@ let pluginsDir = if cfg.dotDir != null then relToDotDir "plugins" else ".zsh/plugins"; - export = n: v: "export ${n}=\"${toString v}\""; - - toEnvVarsStr = vars: concatStringsSep "\n" ( - mapAttrsToList export vars - ); - envVars = cfg.sessionVariables // ( if config.home.sessionVariableSetter == "zsh" then config.home.sessionVariables else {} ); - envVarsStr = toEnvVarsStr envVars; + envVarsStr = config.lib.shell.exportAll envVars; aliasesStr = concatStringsSep "\n" ( mapAttrsToList (k: v: "alias ${k}='${v}'") cfg.shellAliases