Vim environment variable configuration, background color configuration, and vim environment variable background color

Source: Internet
Author: User

Vim environment variable configuration, background color configuration, and vim environment variable background color

When we use vi or vim, if we want to display the row number, we may do this: switch to the command mode, enter set nu, and then press the Enter key to display it; in addition, when programming, sometimes we want to press the Enter key, the cursor is not always at the beginning of the line, but alignment with the first non-space character in the previous line, that is, to achieve the so-called contraction function, you can enter set autoindent in command mode. However, it is too troublesome to input the command like this. Can I set the function automatically every time I use the vim command to edit it?

Briefly describe the configuration steps. The following table shows the vim environment parameters (from laruence's book)

 

The above are the private dishes of laruence. Below is a simple record of my settings. I want to add the function myself and then add it.

1. Run the command cd/etc/vim to enter the configuration directory.

2. Run the command vim vimrc to edit the vimrc file. For ubuntu, run the command sudo vim vimrc.

3. In the last line of the vimrc file, add the options you want to set, which are some of the default functions of vim.

4. Use wq to save the settings.

Http://blog.csdn.net/mybelief321/article/details/9011707

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.