Skip to content

Commit

Permalink
feat: remove neovim from zsh configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
1995parham committed Oct 8, 2023
1 parent b633d77 commit c0ac9b4
Showing 1 changed file with 0 additions and 26 deletions.
26 changes: 0 additions & 26 deletions zsh/zshrc.shared
Original file line number Diff line number Diff line change
Expand Up @@ -187,34 +187,8 @@ if [[ "$(command -v pyenv)" ]]; then
eval "$(pyenv init -)"
fi

# function is defined for using in neovim as an editor
# because zsh cannot parse spaces in the running program.
# https://superuser.com/questions/521070/unix-environment-variables-with-arguments
neditor() {
=nvr -cc split +'set bufhidden=delete' --remote-wait $@
}

# using zsh in neovim terminal mode.
# neovim defines $NVIM in terminal mode and based on it
# we can detect we are running inside neovim and use nvr
# instead of neovim, etc.
if [ ! -z "$NVIM" ]; then
alias nvim=nvr
export EDITOR="neditor"

excl_plugins=(vi-mode)

plugins=${plugins:|excl_plugins}
fi

# use man page with different pagers in different environments
man(){
if [ -n "$NVIM" ]; then
=nvr -c "Man $*"

return 0
fi

# man pages with batman
if [[ "$(command -v batman)" ]]; then
=batman "$@"
Expand Down

0 comments on commit c0ac9b4

Please sign in to comment.