mirror of
https://github.com/neovim/neovim.git
synced 2025-09-06 19:38:20 +00:00
vim-patch:9.1.0770: current command line completion is a bit limited (#30728)
Problem: current command completion is a bit limited
Solution: Add the shellcmdline completion type and getmdcomplpat()
function (Ruslan Russkikh).
closes: vim/vim#15823
0407d621bb
Co-authored-by: Ruslan Russkikh <dvrussk@yandex.ru>
This commit is contained in:
@@ -3611,6 +3611,20 @@ M.funcs = {
|
||||
returns = 'string',
|
||||
signature = 'getcharstr([{expr}])',
|
||||
},
|
||||
getcmdcomplpat = {
|
||||
desc = [=[
|
||||
Return completion pattern of the current command-line.
|
||||
Only works when the command line is being edited, thus
|
||||
requires use of |c_CTRL-\_e| or |c_CTRL-R_=|.
|
||||
Also see |getcmdtype()|, |setcmdpos()|, |getcmdline()|,
|
||||
|getcmdprompt()|, |getcmdcompltype()| and |setcmdline()|.
|
||||
Returns an empty string when completion is not defined.
|
||||
]=],
|
||||
name = 'getcmdcomplpat',
|
||||
params = {},
|
||||
returns = 'string',
|
||||
signature = 'getcmdcomplpat()',
|
||||
},
|
||||
getcmdcompltype = {
|
||||
desc = [=[
|
||||
Return the type of the current command-line completion.
|
||||
@@ -3618,7 +3632,7 @@ M.funcs = {
|
||||
requires use of |c_CTRL-\_e| or |c_CTRL-R_=|.
|
||||
See |:command-completion| for the return string.
|
||||
Also see |getcmdtype()|, |setcmdpos()|, |getcmdline()|,
|
||||
|getcmdprompt()| and |setcmdline()|.
|
||||
|getcmdprompt()|, |getcmdcomplpat()| and |setcmdline()|.
|
||||
Returns an empty string when completion is not defined.
|
||||
]=],
|
||||
name = 'getcmdcompltype',
|
||||
|
Reference in New Issue
Block a user