From 9990269b75c47ce0f095e621c011f48e7667544c Mon Sep 17 00:00:00 2001 From: Minijackson Date: Fri, 18 Aug 2023 21:19:19 +0200 Subject: zsh: follow XDG dirs --- common/commandline/zsh.nix | 34 ++++++++++++++++------------------ 1 file changed, 16 insertions(+), 18 deletions(-) diff --git a/common/commandline/zsh.nix b/common/commandline/zsh.nix index 2fc8c87..1110bf2 100644 --- a/common/commandline/zsh.nix +++ b/common/commandline/zsh.nix @@ -60,27 +60,25 @@ in users.defaultUserShell = pkgs.zsh; - home-manager.users = - let - config = { + home-manager.sharedModules = [ + ({config, ...}: { + programs.zsh = { enable = true; # Completion is already handled by the GRML conf enableCompletion = false; - plugins = [{ - name = "shmart-prompt-dir"; - src = inputs.shmart-prompt-dir; - file = "none"; - }]; - }; - in - { - minijackson = { ... }: { - # Allows zsh config from home-manager - programs.zsh = config; - }; - root = { ... }: { - programs.zsh = config; + # XDG + dotDir = ".config/zsh"; + history.path = "${config.xdg.dataHome}/zsh/zsh_history"; + + plugins = [ + { + name = "shmart-prompt-dir"; + src = inputs.shmart-prompt-dir; + file = "none"; + } + ]; }; - }; + }) + ]; } -- cgit v1.2.3