sponsor Vim development Vim logo Vim Book Ad

AppendToClip : plugin for appending to the default register

 script karma  Rating 13/4, Downloaded by 420  Comments, bugs, improvements  Vim wiki

created by
Scott Updike
 
script type
utility
 
description
Have you ever wanted to yank or copy one line at a time from various parts of a file and be able to paste the accumulated results in one operation? Sure, you can do this using named registers using the uppercase letter, but it is cumbersome and unnatural.  The AppendToClip plugin lets you append to the default register (and the clipboard, and primary registers if the 'clipboard' option contains 'unnamed' or 'unnamedplus') in a natural and easy way.

Functionality

<Space>yy

Append line(s) to the default register, '"'. Also append to the clipboard,
'*', and primary, '+', registers if the 'clipboard' option contains 'unnamed'
and 'unnamedplus', respectively.

<Space>dd

Delete and append line(s) to the default register, '"'. Also append to the
clipboard, '*', and primary, '+', registers if the 'clipboard' option contains
'unnamed' and 'unnamedplus', respectively.

These mappings work in both normal and visual mode and take a count just like
the built in commands 'dd' and 'yy'.

If you have the vim-repeat plugin (https://github.com/tpope/vim-repeat) installed, you can repeat either of the above mappings with dot, '.'.

Options

g:appendtoclip_leader

The key used as the leader to the mappings. The default is <Space>.
 
install details
Extract the plugin files in your ~/.vim (*nix) or ~/vimfiles (Windows). You
should have 2 files:

    plugin/appendtoclip.vim
    doc/appendtoclip.txt

Next, to finish installing the help file run:

    :helptags ~/.vim/doc

Alternatively, and arguably preferably, use Pathogen and checkout the
vim-appendtoclip directory in your bundle directory. Then, run:

    :Helptags
 

rate this script Life Changing Helpful Unfulfilling 
script versions (upload new version)

Click on the package to download.

package script version date Vim version user release notes
appendtoclip.tgz 1.0.4 2015-02-24 7.3 Scott Updike Initial upload
ip used for rating: 3.89.204.127

If you have questions or remarks about this site, visit the vimonline development pages. Please use this site responsibly.
Questions about Vim should go to the maillist. Help Bram help Uganda.
   
OSDN