5 réponses
Hello,
To my knowledge, "vi," in its terminal application version under Linux, does not share its clipboard with applications under X.
However, you can copy and paste what appears in an xterm window by selecting with the mouse, keeping it selected in that xterm window, and clicking the middle button on your three-button mouse in your other application (or using the scroll wheel, or simultaneously clicking the left and right buttons of the mouse in the absence of a middle button).
This only allows you to copy the visible part.
If you really want everything, the simplest thing is to open the text file in your graphical editor.
That said, the link from "coucou_c_julien" is a goldmine of information on "vi," in a compact form that is useful to have handy.
Dal
To my knowledge, "vi," in its terminal application version under Linux, does not share its clipboard with applications under X.
However, you can copy and paste what appears in an xterm window by selecting with the mouse, keeping it selected in that xterm window, and clicking the middle button on your three-button mouse in your other application (or using the scroll wheel, or simultaneously clicking the left and right buttons of the mouse in the absence of a middle button).
This only allows you to copy the visible part.
If you really want everything, the simplest thing is to open the text file in your graphical editor.
That said, the link from "coucou_c_julien" is a goldmine of information on "vi," in a compact form that is useful to have handy.
Dal
I think you can use gvim for this kind of manipulation... Otherwise with the mouse as Dal suggests (copy = selection, paste with the middle click/with the scroll wheel)
Good luck
Good luck
Otherwise, you have mouse support with the option set mouse=a
http://doc.ubuntu-fr.org/vim#vim_supporte_les_souris
You need to install gpm beforehand, for example on ubuntu by typing:
Then configure your vimrc:
You also have graphical interfaces that embed vim like gvim.
http://doc.ubuntu-fr.org/vim#vim_supporte_les_souris
You need to install gpm beforehand, for example on ubuntu by typing:
sudo apt-get update sudo apt-get upgrade sudo apt-get install gpm
Then configure your vimrc:
echo "set mouse=a" >> ~/.vimrc
You also have graphical interfaces that embed vim like gvim.