If you're new here, you may want to subscribe to my RSS feed. Thanks for visiting!
Administrators who wish to change the default editor for all users will have to update the alternatives system using:
# update-alternatives --config editor
Once you enter it opens available editor options from your server you should see similar to the following screen here i have selected option4 for vi editor

If you are an user wishing to change the default editor can define the environment variable EDITOR by introducing the following lines in their own profiles
EDITOR=vi
export EDITOR
alias editor=$EDITOR
You may also be interested in...