Files
nix/hosts/common/user/configs/console/zsh/default.nix
2024-08-08 22:03:15 +03:00

29 lines
666 B
Nix

{
user ? throw "user argument is required",
home ? throw "home argument is required",
}:
{ config, ... }:
{
environment = {
sessionVariables.ZDOTDIR = "$HOME/.config/zsh";
persistence."/persist"."${home}/.local/share/zsh" = { };
};
home-manager.users.${user} = {
programs.zsh = {
enable = true;
dotDir = ".config/zsh";
autocd = true;
history = {
path = "${home}/.local/share/zsh/history";
expireDuplicatesFirst = true;
};
historySubstringSearch.enable = true;
autosuggestion.enable = true;
syntaxHighlighting.enable = true;
};
home.file.".zshenv".enable = false;
};
}