fasd.plugin.zsh 419 Bytes
Newer Older
Alexander Berezovsky's avatar
Alexander Berezovsky committed
1
if [ $commands[fasd] ]; then # check if fasd is installed
2
  fasd_cache="${ZSH_CACHE_DIR}/fasd-init-cache"
3
  if [ "$(command -v fasd)" -nt "$fasd_cache" -o ! -s "$fasd_cache" ]; then
4
5
    fasd --init posix-alias zsh-hook zsh-ccomp zsh-ccomp-install \
      zsh-wcomp zsh-wcomp-install >| "$fasd_cache"
6
7
8
  fi
  source "$fasd_cache"
  unset fasd_cache
9

10
  alias v='f -e "$EDITOR"'
11
  alias o='a -e xdg-open'
12
  alias j='zz'
Alexander Berezovsky's avatar
Alexander Berezovsky committed
13
fi