crontab -e defaults to using
vi for editing.
This is not usually a problem.
vi is an excellent editor, and easy to learn.
Recently I've begun to use
vim which is installed by
sudo apt-get update sudo apt-get install vim
and in order to make it show line numbers and default to proper numbers of spaces when Tab is pressed, plus syntax highlighting for Python development,
the contents of my
/home/username/.vimrc file is as so:
syntax enable set number set ts=4 set autoindent set expandtab set shiftwidth=4 set cursorline set showmatch let python_highlight_all = 1
This works out great.
However, when I use
crontab -e it gives the following error messages:
Sorry, the command is not available in this version: syntax enable
Sorry, the command is not available in this version: let python_highlight_all = 1
Press ENTER or type command to continue
Then pressing Enter allows it to continue into
vi for editing of the cron table.
Questions: What version of vi is it trying to use? Is there a way to set it to the normal vim? Or to set it to another editor?