On Sun, May 2, 2010 at 14:16, John Little <john.b.lit...@gmail.com> wrote: > > On May 2, 10:45 pm, Raúl Núñez de Arenas Coronado <raul...@gmail.com> > wrote: >> First one is copying and pasting the map... > > How about a level of indirection using :exe : > > let mapped = "<silent><buffer> <LocalLeader>KEY " > let mapping = "m'gg\"+yG\"" > exe 'nnoremap ' . mapped . mapping > exe 'inoremap ' . mapped . '<esc>' . mapping . 'i' > > I don't know how usable this is, I just checked :map output to see > that the mappings had been made. > > You could extend this to a general function, f. ex. > call Makemaps(mapped, mapping, modes) > > Regards, John > > -- > You received this message from the "vim_use" maillist. > Do not top-post! Type your reply below the text you are replying to. > For more information, visit http://www.vim.org/maillist.php >
-- Raúl "DervishD" Núñez de Arenas Coronado Linux Registered User 88736 | http://www.dervishd.net The revolution will not be televised -- You received this message from the "vim_use" maillist. Do not top-post! Type your reply below the text you are replying to. For more information, visit http://www.vim.org/maillist.php