aboutsummaryrefslogtreecommitdiff
path: root/modules/user/zsh
diff options
context:
space:
mode:
Diffstat (limited to 'modules/user/zsh')
-rw-r--r--modules/user/zsh/default.nix25
-rw-r--r--modules/user/zsh/zshrc.zsh1
2 files changed, 26 insertions, 0 deletions
diff --git a/modules/user/zsh/default.nix b/modules/user/zsh/default.nix
new file mode 100644
index 0000000..6f49406
--- /dev/null
+++ b/modules/user/zsh/default.nix
@@ -0,0 +1,25 @@
+{
+ config,
+ lib,
+ options,
+ ...
+}:
+{
+ config.programs.zsh = {
+ enable = lib.mkDefault true; # default user shell
+ autocd = true;
+ autosuggestion = {
+ enable = lib.mkDefault true;
+ strategy = [
+ "history"
+ "completion"
+ ];
+ };
+
+ history.ignoreAllDups = true;
+ initContent = builtins.readFile ./zshrc.zsh;
+ #loginExtra = builtins.readFile ./zlogin.zsh;
+ setOptions = [ "extendedglob" ];
+ syntaxHighlighting.enable = true;
+ };
+}
diff --git a/modules/user/zsh/zshrc.zsh b/modules/user/zsh/zshrc.zsh
new file mode 100644
index 0000000..9b2083a
--- /dev/null
+++ b/modules/user/zsh/zshrc.zsh
@@ -0,0 +1 @@
+PS1='%F{8}%(?..(%F{1}%?%F{8}%)-)[%F{1}%n@%M%F{8}]:%F{1}%5~%F{8}%# %f'