Hi,

On Sun, Jun 9, 2019 at 9:15 AM Yegappan Lakshmanan <[email protected]> wrote:
>
> >
> > Yegappan wrote:
> >
> > > The expand() function can be used to expand special characters. If the
> > > special characters appears anywhere in the command string, then this
> > > cannot be used.
> > >
> > > Vim supports expanding special characters anywhere in a command string
> > > for internal commands. For example, the 'makeprg' option accepts a command
> > > string where special characters can occur anywhere in the string.
> > > But a Vim plugin cannot support this. So plugins like dispatch.vim use a 
> > > complicated
> > > function to expand the special characters (look at the dispatch#expand() 
> > > function in
> > > https://github.com/tpope/vim-dispatch/blob/master/autoload/dispatch.vim).
> > >
> > > This patch adds a expandcmd() function that can be used to expand all the
> > > special characters in a command string.
> >
> > Thanks. I updated the docs to mention that the expansion happens like
> > for the ":edit" command. Other commands, such as ":next" work slightly
> > differently.
> >
>
> Thanks for merging the patch. Hopefully this is sufficient for plugins
> to expand options like 'makeprg', 'grepprg', 'equalprg', 'formatprg',
> 'keywordprg', etc.
>

This will be useful for plugins which parse the above options and
start a job asynchronously using job_start(). To do this, these
plugins need to expand the special items in the above options
and then pass the resulting strings as arguments to job_start().

- Yegappan

-- 
-- 
You received this message from the "vim_dev" 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_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/vim_dev/CAAW7x7mG68hwa0bGfStBNAQ7od5eSmX%3DgxEXx24pboYLFnMqiA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Raspunde prin e-mail lui