Save the following script in /usr/local/bin/cpvim
#!/bin/zshsource ~/.zshrc > /dev/null 2>&1PATH=$VIM_PATHexec nvim "$@"Add the following to your .zshrc
alias vim=/usr/local/bin/cpvimSave the following script in /usr/local/bin/cpvim
#!/bin/zshsource ~/.zshrc > /dev/null 2>&1PATH=$VIM_PATHexec nvim "$@"Add the following to your .zshrc
alias vim=/usr/local/bin/cpvim@online{krishnamurthy2015changepathinsidevim,
author = {Dheepak Krishnamurthy},
title = {Change `$PATH` inside vim},
year = {2015},
date = {2015-09-19},
url = {https://kdheepak.com/blog/change-path-inside-vim/},
langid = {en},
} For attribution, please cite this work as:
Dheepak Krishnamurthy, "Change `$PATH` inside vim", September 19, 2015 https://kdheepak.com/blog/change-path-inside-vim/