zsh: fix HISTFILE setup
Alan Pearce alan@alanpearce.eu
Tue, 29 Dec 2020 12:43:31 +0100
1 files changed, 4 insertions(+), 1 deletions(-)
jump to
M user/settings/zsh.nix → user/settings/zsh.nix
@@ -36,6 +36,9 @@ if [[ ! -f ${config.home.sessionVariables.XDG_DATA_HOME}/zsh/history ]]; then mkdir -p ${config.home.sessionVariables.XDG_DATA_HOME}/zsh/ ln ~/.cache/zsh/history ${config.home.sessionVariables.XDG_DATA_HOME}/zsh/history fi + if [[ ! -d "${config.home.sessionVariables.XDG_CACHE_HOME}/zsh" ]]; then + mkdir -p ${config.home.sessionVariables.XDG_CACHE_HOME}/zsh + fi ''; programs.zsh = { @@ -50,7 +53,7 @@ history = { expireDuplicatesFirst = true; extended = true; - path = "\${XDG_DATA_HOME#$HOME/}/zsh/history"; + path = "\${XDG_DATA_HOME}/zsh/history"; save = 20000; size = 10000; share = false;