Vim Copy and Paste X11 Clipboard with xclip - Linux VIM

preview_player
Показать описание

-------------

xclip is a command line utility that is designed to run on any system with an X11 implementation. It provides an interface to X selections ("the clipboard") from the command line. It can read data from standard in or a file and place it in an X selection for pasting into other X applications. xclip can also print an X selection to standard out, which can then be redirected to a file or another program.
Рекомендации по теме
Комментарии
Автор

Like this much better than the gvim solution. Thanks for posting: Old but still good!

craigw
Автор

This works by default on neovim when you have xclip or xsel installed.

brandonduvalbenn
Автор

Another great video. Thanks for all of your great content.

prahe
Автор

I just hold down the left mouse button and swipe across the text to copy. Then place your cursor where you want to paste, and hit the center roller/button. Text copied. Simple. Stock Debian.

noferblatz
Автор

CTRL + Alt + V works too. Not in St or urxvt for some reason, but in most terminals that come with a DE.

BurekOne
Автор

I don't really understand why you need this xclip workaround? If you have vim compiled with +clipboard (check vim --version | grep clipboard) you can just set: "set clipboard^=unnamed, unnamedplus" in your vimrc to use the system clipboard in vim

Etileable
Автор

An issue I always have is that I SSH into another machine, and xclip would not help if I want to copy to a local machine

yolandyan
Автор

Really Thanks, I recent start with vim

efra-rz
Автор

I think on voidlinux, there is a vim version compiled with xclip/xsel support without the gui. I'm not sure but I read it somewhere. I strongly believe every distro should do so.

nilsirl
Автор

but, it cannot copy-paste per-character. how to solved issue?

mandasialearn
Автор

I'm using Linux inside of ChromeOS and can't get any solution to work, the only way I can copy anything and bring it outside of the Linux environment is by highlighting the text I want to copy in the terminal (which I can't do in Vim) so I resorted to "cat ./filename" and then copying it that way. 😁

Emil_Jansson
Автор

It's always painful to watch people doing this instead of compiling themselves
Couple minutes of work and you'll be able to "+y "+p

hijacked