Skip to content

Instantly share code, notes, and snippets.

@Johnytran
Last active June 16, 2016 01:01
Show Gist options
  • Save Johnytran/d7cd566a5deb914135c7cf92e9d23b7e to your computer and use it in GitHub Desktop.
Save Johnytran/d7cd566a5deb914135c7cf92e9d23b7e to your computer and use it in GitHub Desktop.
copy cut paste
To cut-and-paste or copy-and-paste:
Position the cursor at the beginning of the text you want to cut/copy.
Press v to begin character-based visual selection, or V to select whole lines, or Ctrl-v or Ctrl-q to select a block.
Move the cursor to the end of the text to be cut/copied. While selecting text, you can perform searches and other advanced movement.
Press d (delete) to cut, or y (yank) to copy.
Move the cursor to the desired paste location.
Press p to paste after the cursor, or P to paste before.
above for buffer inside vim
Now all operations such as yy, D, and P work with the clipboard. No need to prefix them with "* or "+.
for clipboard OS
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment