From e4c2a870150e196fbb9bc2c9b55cb276f277d633 Mon Sep 17 00:00:00 2001 From: Dmytro Meleshko Date: Sun, 21 Mar 2021 12:17:57 +0200 Subject: [PATCH] [zsh] install fasd if it's not present, also change the database path --- zsh/plugins.zsh | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/zsh/plugins.zsh b/zsh/plugins.zsh index f207b1c..322707d 100644 --- a/zsh/plugins.zsh +++ b/zsh/plugins.zsh @@ -64,7 +64,16 @@ _plugin completions 'zsh-users/zsh-completions' "$_checkout_latest_version" # fasd {{{ + if ! command_exists fasd; then + _plugin fasd 'clvv/fasd' \ + build='mkdir -pv man1 && cp -v ./fasd.1 man1/' + after_load='plugin-cfg-path path prepend ""' \ + after_load='plugin-cfg-path manpath prepend ""' + fi + if command_exists fasd; then + export _FASD_DATA="${XDG_DATA_HOME:-$HOME/.local/share}/fasd_db.csv" + # Initialization taken from fasd_cache="${ZSH_CACHE_DIR}/fasd-init-cache" if [[ "${commands[fasd]}" -nt "$fasd_cache" || ! -s "$fasd_cache" ]]; then