dotfiles/.config/zsh/.zshenv
tastytea 35c2fc187a
zsh: change VISUAL in non-interactive shells, too
`:terminal foo` will spawn a non-interactive shell that doesn't read
.zshrc but .zshenv.
2022-09-03 03:33:38 +02:00

10 lines
329 B
Bash

[[ -d "${ZDOTDIR}"/functions ]] && fpath+=( "${ZDOTDIR}"/functions )
[[ -d "${ZDOTDIR}"/completions ]] && fpath+=( "${ZDOTDIR}"/completions )
fpath=(${(u)fpath})
# Open files from :terminal in parent instance
if [[ -v NVIM ]]; then
export VISUAL="$(command -v nvim) --server ${NVIM} --remote"
export EDITOR=${VISUAL}
fi