From 0872808b7a9e119064a8d53365a93deff04d230b Mon Sep 17 00:00:00 2001 From: Price Hiller Date: Sat, 7 Sep 2024 13:35:01 -0500 Subject: [PATCH] refactor(hm/price): use `z.lua` via home manager not zsh --- .gitmodules | 3 --- users/price/conf/zsh/default.nix | 27 ++++++++++++------- .../dots/.config/zsh/config/plugins/init.zsh | 3 --- .../dots/.config/zsh/config/plugins/z.lua | 1 - 4 files changed, 18 insertions(+), 16 deletions(-) delete mode 160000 users/price/dots/.config/zsh/config/plugins/z.lua diff --git a/.gitmodules b/.gitmodules index 6e983b51..7bf21cc7 100644 --- a/.gitmodules +++ b/.gitmodules @@ -10,9 +10,6 @@ [submodule "dots/.config/zsh/config/plugins/fzf-tab"] path = users/price/dots/.config/zsh/config/plugins/fzf-tab url = https://github.com/Aloxaf/fzf-tab.git -[submodule "dots/.config/zsh/config/plugins/z.lua"] - path = users/price/dots/.config/zsh/config/plugins/z.lua - url = https://github.com/skywind3000/z.lua.git [submodule "dots/.config/zsh/config/plugins/nix-zsh-completions"] path = users/price/dots/.config/zsh/config/plugins/nix-zsh-completions url = https://github.com/spwhitt/nix-zsh-completions diff --git a/users/price/conf/zsh/default.nix b/users/price/conf/zsh/default.nix index 818a80e3..708ed9a6 100644 --- a/users/price/conf/zsh/default.nix +++ b/users/price/conf/zsh/default.nix @@ -1,13 +1,22 @@ { config, ... }: { - programs.zsh = { - enable = true; - enableCompletion = true; - initExtra = builtins.readFile ./init-extra.zsh; - completionInit = - let - zsh-cache-dir = "${config.xdg.cacheHome}/zsh"; - in - "mkdir -p ${zsh-cache-dir} && autoload -U compinit && compinit -d ${zsh-cache-dir}/zcompdump-$ZSH_VERSION"; + programs = { + z-lua = { + enable = true; + options = [ + "enhanced" + "once" + ]; + }; + zsh = { + enable = true; + enableCompletion = true; + initExtra = builtins.readFile ./init-extra.zsh; + completionInit = + let + zsh-cache-dir = "${config.xdg.cacheHome}/zsh"; + in + "mkdir -p ${zsh-cache-dir} && autoload -U compinit && compinit -d ${zsh-cache-dir}/zcompdump-$ZSH_VERSION"; + }; }; } diff --git a/users/price/dots/.config/zsh/config/plugins/init.zsh b/users/price/dots/.config/zsh/config/plugins/init.zsh index 7d53754a..39f2fb2c 100644 --- a/users/price/dots/.config/zsh/config/plugins/init.zsh +++ b/users/price/dots/.config/zsh/config/plugins/init.zsh @@ -17,9 +17,6 @@ init() { FPATH="${FPATH}:${wkdir}/nix-zsh-completions" - export _ZL_DATA="${_ZL_DATA:-"$XDG_CACHE_HOME/zlua"}" - eval "$(lua "${wkdir}/z.lua/z.lua" --init zsh enhanced once)" - [[ -r "${XDG_CONFIG_HOME}/fzf/fzf.zsh" ]] && source "${XDG_CONFIG_HOME}/fzf/fzf.zsh" configure diff --git a/users/price/dots/.config/zsh/config/plugins/z.lua b/users/price/dots/.config/zsh/config/plugins/z.lua deleted file mode 160000 index 30220996..00000000 --- a/users/price/dots/.config/zsh/config/plugins/z.lua +++ /dev/null @@ -1 +0,0 @@ -Subproject commit 30220996cae675f9ec12fc3aeb2b5c3d957af8c8