Set EDITOR in .bashrc

This commit is contained in:
Kenneth Benzie 2023-10-28 23:16:18 +01:00
parent 9017be5cf7
commit c4ac91f163

View File

@ -113,3 +113,10 @@ PS1="$yellow\u$reset@$grey\h$reset "
# Setup environment variables
export PATH=$HOME/.local/bin:$PATH
if command -v nvim > /dev/null; then
export EDITOR=nvim
elif command -v vim > /dev/null; then
export EDITOR=vim
elif command -v vi > /dev/null; then
export EDITOR=vi
fi