Ubuntu content copied to browser under VIM

Source: Internet
Author: User

In vim to edit the code want to copy out to the browser or other places, with YY copied to another place to stick to find that is not the original copy of the content, very headache ...

This is because VIM has its own set of Clipboard systems (clipboard) that are not interoperable with Ubuntu's clipboard.

After seeing a lot of posts saying you've selected what you want, press 3 keys "+y" (quotation marks, plus sign, and letter Y) so that what you want to copy goes into the system Clipboard.

That's only half right. ~_~

1. First to check if your vim version supports +clipboard, the command is: version

Or you can enter: Reg to see if the X and + registers are included

2. If there is support, then the method mentioned above can be, otherwise:

Need to install Vim-gnome

sudo apt-get install Vim-gnome
Open file to compile file gvim-v filename

Then you can use the +y.

Alias can be defined in. bashrc

Alias GVi = ' Gvim-v '

The next time you open the file, just use GVi filename.


Ubuntu content copied to browser under VIM

Related Article

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.