亚洲在线久爱草,狠狠天天香蕉网,天天搞日日干久草,伊人亚洲日本欧美

為了賬號安全,請及時綁定郵箱和手機立即綁定

正在回答

2 回答

好好好


0 回復 有任何疑惑可以回復我~

https://vi.stackexchange.com/questions/84/how-can-i-copy-text-to-the-system-clipboard-from-vim


gVim

If you use gVim, you can get copy-on-select behaviour when using?:set guioptions+=a.
This is enabled by default on X11 systems (copies to PRIMARY), but?not?on MS Windows & OSX (as selecting any text would override your clipboard).

No?+clipboard?

Vim requires the?+clipboard?feature flag for any of this to work; you can check if your Vim has this by using?:echo has('clipboard')?from within Vim (if the output is?0, it?not?present, if it's?1, it is), or checking the output of?vim --version.

Most Linux distributions ship with a "minimal" Vim build by default, which doesn't have?+clipboard, but you can usually install it:

  • Debian & Ubuntu: Install?vim-gtk?or?vim-gnome.

  • Fedora: install?vim-X11, and run?vimx?instead of?vim?(more info).

  • Arch Linux: install?gvim?(this will enable?+clipboard?for normal?vim?as well).

You could also use?xclip,?xcopy, or?xsel?to copy text to the clipboard; see the following questions for solutions:


0 回復 有任何疑惑可以回復我~

舉報

0/150
提交
取消
玩轉Vim 從放棄到愛不釋手
  • 參與學習       28622    人
  • 解答問題       78    個

作為程序員你還不知道編輯器之神 Vim 嗎,帶你從零開始學習 vim 編輯器。

進入課程
微信客服

購課補貼
聯系客服咨詢優惠詳情

幫助反饋 APP下載

慕課網APP
您的移動學習伙伴

公眾號

掃描二維碼
關注慕課網微信公眾號