Skip to content

Commit

Permalink
zsh: support extra settings in oh-my-zsh plugins (#1106)
Browse files Browse the repository at this point in the history
Co-Authored-By: Robert Helgesson <robert@rycee.net>
  • Loading branch information
Carlos Tomé and rycee committed Mar 25, 2020
1 parent 78a0bbb commit 7fa8904
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions modules/programs/zsh.nix
Original file line number Diff line number Diff line change
Expand Up @@ -152,6 +152,17 @@ let
Name of the theme to be used by oh-my-zsh.
'';
};

extraConfig = mkOption {
default = "";
example = ''
zstyle :omz:plugins:ssh-agent identities id_rsa id_rsa2 id_github
'';
type = types.lines;
description = ''
Extra settings for plugins.
'';
};
};
};

Expand Down Expand Up @@ -398,6 +409,8 @@ in
${envVarsStr}
${optionalString cfg.oh-my-zsh.enable ''
# oh-my-zsh extra settings for plugins
${cfg.oh-my-zsh.extraConfig}
# oh-my-zsh configuration generated by NixOS
${optionalString (cfg.oh-my-zsh.plugins != [])
"plugins=(${concatStringsSep " " cfg.oh-my-zsh.plugins})"
Expand Down

0 comments on commit 7fa8904

Please sign in to comment.