Wednesday, July 2, 2014

Re: map a chain of commands

On Wed, 2 Jul 2014 16:35:46 -0500
Tim Chase <vim@tim.thechases.com> wrote:

>On 2014-07-02 22:07, Tarlika Elisabeth Schmitz wrote:
>> >> > :nnoremap <buffer> <f4> :for idx in [3,18,6]<bar>let
>> >> > val=split(getline('.'), '\t')[idx-1]<bar>if strlen(val)<bar>let
>> >> > @+=val<bar>call input('Press enter
>> >> > #'.idx)<bar>endif<bar>endfor<cr>
>>
>> It doesn't do anything, neither prompts me to enter nor puts
>> anything in the clipboad.
>
>You're typing it all as one line? I tested it with a tab-separated
>file I've got here and it (at least with the "call input(...)"
>fragment) worked exactly as expected.


I placed it in .vimrc with "call input", all in one line, just changed
F4 to F12, exited vim. Nothing happens when I press F12.

--
Tarlika






--

Tarlika Elisabeth Schmitz, Scotland
http://my.mutterings.co.uk/

--
--
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

---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment