Ever wanted to change the crontab of a server, but got an editor on screen that you’re totally unfamiliar with? There are a lot of causes for this annoyance, but one is that somebody recently installed or used midnight commander (mc) which for whatever reason seams to overrule your session’s default editor.
Changing the editor
The first time it took me a while to figure it out so I thought lets make it an article on my site, so maybe it will help others save some time.
Anyhow, here how to change it, just open your terminal and type
1
| |
pico can be pico, vim, or another text editor of your choice of course.
Make it permanent
If the problem persists, you might want to add the export to your .bashrc file, or even to the /etc/profile file. But that seems a bit radical since that’s system-wide : )
Debian / Ubuntu
As noted by Roland below, on Debian / Ubuntu you can use:
1
| |
Much better!
Imported comments
These were imported from my old blog. Please use disqus below for new comments
neeraj
on 2012-01-11 11:20:17
I have gone through your site and find that
You are simply a great person….
Good Work and keeping posting …
God Bless U :)
–neeraj
Ashish Sood
on 2010-05-23 22:15:30
Usefull topic
thanks Alot
Buddhika
on 2009-02-10 05:12:01
Thank a lot that is very usefull
jonw
on 2008-12-11 20:45:42
Thanks for that tip… Worked perfectly.
Kevin
on 2008-11-25 16:58:05
@ Roland: Didn't know that, only used it for java so far. Thanks Roland!
Roland
on 2008-11-18 14:02:06
on Debian orUbuntu you can use:
sudo update-alternatives –config editor