Sunday, February 18, 2018

Re: write to command0line prompt

On 2018-02-18 13:05, Renato Fabbri wrote:
> :normal :ls
> does not leave the user with the cursor at the command-line, e.g.
> in: :ls
>
> Is there a way to write a function or is there a command I might
> use to leave the user with a given string in the command-line?

A mapping can leave you at the prompt if you don't append "<cr>" to
it:

:nnoremap <f2> :ls

Without knowing the context and what you're hoping to do with it,
it's hard to give much more detail.

-tim


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