46 lines
1.1 KiB
Nix
46 lines
1.1 KiB
Nix
{ config, lib, ... }: lib.mkIf config.programs.zsh.enable {
|
|
programs = {
|
|
zsh = {
|
|
defaultKeymap = "emacs";
|
|
dotDir = ".config/zsh";
|
|
shellAliases = {
|
|
j = "z";
|
|
ji = "zi";
|
|
};
|
|
initExtra = builtins.readFile ../../../../configs/home-manager/zsh/zshrc.zsh;
|
|
autosuggestion.enable = true;
|
|
completionInit = ''
|
|
autoload -U compinit bashcompinit
|
|
compinit
|
|
bashcompinit'';
|
|
history = {
|
|
path = "${config.xdg.cacheHome}/zsh_history";
|
|
save = 100000;
|
|
size = 100000;
|
|
share = true;
|
|
extended = true;
|
|
};
|
|
historySubstringSearch = {
|
|
enable = true;
|
|
searchDownKey = [
|
|
"^[[B"
|
|
];
|
|
searchUpKey = [
|
|
"^[[A"
|
|
];
|
|
};
|
|
zplug = {
|
|
enable = true;
|
|
plugins = [
|
|
{ name = "zdharma-continuum/fast-syntax-highlighting"; }
|
|
{ name = "nix-community/nix-zsh-completions"; }
|
|
];
|
|
};
|
|
envExtra = ''
|
|
export DIRENV_LOG_FORMAT=$'\033[2mdirenv: %s\033[0m'
|
|
export DOOMWADDIR=$HOME/Games/doom/IWADs
|
|
'';
|
|
};
|
|
};
|
|
}
|