Paste-To-Terminal Keyboard Shortcuts

By | 2007/02/25

Update: as pointed out by SFA_AOK in the comments two more shortcuts have been added.

For ages man has toiled with pasting data into a terminal window by using the mouse. Right-Click, paste. Middle-click, Paste. Its all very tedious for all of us keyboard warriors. Those of us that are slowed down by the mouse and its pagan graphical goodness. No more! I present to you keyboard shortcuts that work within the terminal!

ctrl-insert : copy

shift-insert : paste

shift-delete : cut

shift-ctrl-C : copy

shift-ctrl-V : paste

Really. Give it a try. Copy something. Open a terminal. Paste. Mouse not required. What a beautiful day it is to be a keyboard warriors. You learn something new everyday.

(queue the small print) yes it is a little weird to get used to new shortcuts but it’ll be worth it. Plus, for those of us using Dvorak anyway the old-fashioned ctrl c v x aren’t in optimal positions anyway. Thanks goes to Aaron for sharing this tidy little nugget of keyboard goodness.

22 thoughts on “Paste-To-Terminal Keyboard Shortcuts

  1. SFA_AOK

    Maybe I’ve missed the point but: what was wrong with ctrl-shift C and ctrl-shift V?

    Reply
  2. SFA_AOK

    Ah OK, just wanted to make sure you weren’t talking about something else that I was missing out on :)

    Reply
  3. Derek Buranen

    For the record, Christer is talking about KDE’s Konsole.

    Thanks for these as I never new copy or cut. I miss gnome-terminal’s shift+ctrl+c though.

    Reply
  4. Patrick

    “Also, what exactly is shift-delete doing?”

    I’m not sure about gnome, but in KDE shift+delte just deletes a file instead of moving it to the trash.

    Reply
  5. Pingback: Copia e incolla nel terminale, un paio di trucchetti at Yaab

  6. Sam

    how do you select the stuff to copy and paste?

    And since your hand is already on the mouse to select, why shift your hand to the keyboard to do the rest?

    Reply
  7. GiM

    Thanks, I was looking how to paste into (u)xterm with keyboard, shift-insert works for me.

    Reply
  8. Rocco Stanzione

    One of my favorites is “!!”, which gets expanded to your last full command. Like, “vi /etc/apt/sources.list” – oops, “sudo !!”. Or, “rm testfile.c”, “svn !!”. Or, “find . -name ‘*!'” followed by “rm $(!!)”. You get the idea.

    Reply
  9. beerfan

    The ctrl-shift-c and ctrl-shift-v keystrokes have to be some of the worst inspired ever.

    Reply
  10. roxport

    Works for pasting things from web browser (Win PC IE) into vi (PuTTY session, using screen).

    Reply
  11. magaphoto

    (humor)

    You had me until you said you were using Dvorak keyboarding.

    It reminded me of the scene in “Raising Arizona” whence the old con os stream-of-conciousness(ing) on the top bunk and he mentions “We ate sand.”

    (Thanks for the hint. Useful.)

    magaphoto

    Reply
  12. David Marsden

    If you want to use Ctrl-C and Ctrl-V for cut and paste you can use Alt-F2 > gconf-editor > apps > gnome-terminal > keybindings > look for copy and paste > right-click > edit key > delete

    Reply
  13. Pingback: HackyPunk » Blog Archive » Paste-To-Terminal Keyboard Shortcuts : Ubuntu Tutorials : Dapper – Feisty – Gutsy – Hardy

  14. Bob

    Doesn’t work :(

    I suppose this only works in a specific, unmentioned terminal? I’m using xterm in openbox in Debian.

    Reply
  15. Aree

    In regard to change keybinding for copy to CTRL-C – This is not a good idea as in all LINUX based systems CTRL-C is reserved for killing a running process

    Reply
  16. Pablo Pages

    I ‘m trying to perform the instructions below but I am cofused.
    Copy and paste means type in the Terminal window as well?
    Thans for your help.
    TERMINAL
    Launch a Terminal window (in /Applications/Utilities) and copy and paste:
    sudo /Applications/TextEdit.app/Contents/MacOS/TextEdit /etc/hosts

    Reply
  17. Oimel

    Great!!!
    I searched a long time, I had HyperTerminal 7.0 PE – for 21 days…
    Now I can use my favourite again: Putty

    Thanks a lot, mate, you saved my day :D

    Reply
  18. Pingback: How to Paste with the Keyboard | omigassplus

Leave a Reply

Your email address will not be published. Required fields are marked *