Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Change the default editor of crontab to vim in debian

2025-01-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >

Share

Shulou(Shulou.com)06/03 Report--

Ebian terminal default editor is nano, such as crontab-e will open nano, this editor is not used to, want to change to vim, of course, your debian system must first install vim. If vim is not installed, enter the following command:

1apt-get install vim

If installed. Enter the following command:

View sourceprint?1update-alternatives-config editor

Here are three options:

01root@fyhqy:~# update-alternatives-there are three candidates for config editor02 to replace editor (provide / usr/bin/editor). 03

04 Select path priority status 05While 06* 0 / bin/nano 40 automatic mode 071 / bin/nano 40 manual mode 082 / usr/bin/vim.basic 30 manual mode 093 / usr/bin/vim.tiny 10 manual mode 10

11 to maintain the current value [*] press enter, or type the selected number: 212update-alternatives: use / usr/bin/vim.basic to provide / usr/bin/editor (editor), in manual mode.

Then select / usr/vim/vim.basic and OK (just enter the number and try again to see if it has become vim).

The difference between vim.tiny and vim.basic is that vim.basic is a full vim, while vim.tiny is a simplified version, which is functionally different, such as not supporting highlights, etc.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 260

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Internet Technology

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report