My Avatar

LanternD's Castle

PhD Student in ECE @ MSU

Install Vim for Local User

2019-06-05

A short post showing how to install vim for local user. For my own record

Why do I need to install vim for local user?

Sometimes I ssh to other servers to develop code. The server is shared with many other people. If you update the vim using sudo, other people’s .vimrc may encounter problems. So we install our own version, and keep the environment clean.

Steps

Basically I follow this website: Is it possible to install vim for a user? - StackOverflow.

1
2
git clone https://github.com/vim/vim.git
cd vim/src
1
alias vim="$HOME/.local/bin/vim"

Note: I tried to add $HOME/.local/bin to $PATH but failed. The vim is still the old version. The alias works for me.

End

Now there is no “Unknown option: relativenumber” error showing up when I open vim.



Disqus Comment 0