Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Gpm provides mouse support to text-based Linux applications like the Emacs editor and the Midnight Commander file management system. Gpm also provides console cut-and-paste operations using the mouse and includes a program to allow pop-up menus to appear at the click of a mouse button.
I'm okay with using the mouse to copy-paste from a terminal, but because the terminal might interpret characters differently I wanted to by-pass it completely, sort of like redirecting output to the clipboard. I guess there's no easy way to do this, otherwise google would have found something by now...
I'm familiar with redirection, the example I give in my first post is pretty straight-forward: I'm wondering if there is some series of shell commands that will allow me to easily redirect output to the clipboard.
i.e. say I have some text "bar" in file "foo.txt". Currently inorder to get these contents into the copy buffer I need to do something like "cat foo.txt" then copy-paste the console output. This is both tedious and prone to error as I discovered with certain non-ASCII data. So what I'd like to be able to do instead is directly insert something into the copy-buffer. The only solution I've found to do this is xclip, so I'm wondering if there are any, more native, alternatives.
Can you give an example of what you can't do; without posting "cat foo.txt > clipboard". What do you intend to do with what winds up in the clipboard?
The most classic example that I can come up with is how to copy text from a browser screen to a gnome terminal. In the browser, merely highlight and CTL-C, and in the terminal use "ALT-P". But, as others mentioned, this is a function of the gnome-terminal.
To be honest, the idea came from these forums when I wanted to post the output of various logs in pastebin. Gedit garbled some of them and high-lighting from the console seemed primitive, I just thought there would be a better way, like "cat foo.log > clipboard", go to pastebin, ctrl+v.