diff options
-rw-r--r-- | autoload/lsp_settings.vim | 6 | ||||
-rw-r--r-- | schema.json | 4 | ||||
-rw-r--r-- | settings.json | 7 | ||||
-rw-r--r-- | settings/html-languageserver.vim | 2 |
4 files changed, 10 insertions, 9 deletions
diff --git a/autoload/lsp_settings.vim b/autoload/lsp_settings.vim index e0160de..fcbcc98 100644 --- a/autoload/lsp_settings.vim +++ b/autoload/lsp_settings.vim @@ -331,9 +331,9 @@ function! s:vim_lsp_load_or_suggest(ft) abort if get(g:, 'lsp_loaded', 0) for l:server in s:settings[a:ft] - let l:pattern = get(l:server, 'asyncomplete-refresh-pattern', '') - if !empty(l:pattern) - let b:asyncomplete_refresh_pattern = l:pattern + let l:refresh_pattern = get(l:server, 'refresh_pattern', '') + if !empty(l:refresh_pattern) + let b:asyncomplete_refresh_pattern = l:refresh_pattern endif endfor endif diff --git a/schema.json b/schema.json index 38c11d6..95cd0f7 100644 --- a/schema.json +++ b/schema.json @@ -8,8 +8,8 @@ "additionalProperties": false, "description": "define command description", "properties": { - "asyncomplete-refresh-pattern": { - "description": "define refresh pattern for asyncomplete", + "refresh_pattern": { + "description": "loop left and find the start of the word or trigger chars and set it as the startcol for the source instead of refresh_pattern", "type": "string" }, "command": { diff --git a/settings.json b/settings.json index d6fe430..5bc7c4d 100644 --- a/settings.json +++ b/settings.json @@ -63,7 +63,7 @@ ], "css": [ { - "asyncomplete-refresh-pattern": "\\(-\\?[a-zA-Z_]\\+[_a-zA-Z0-9-]*$\\|\\k\\+$\\)", + "refresh_pattern": "\\(-\\?[a-zA-Z_]\\+[_a-zA-Z0-9-]*$\\|\\k\\+$\\)", "command": "css-languageserver", "requires": [ "npm" @@ -189,6 +189,7 @@ ], "html": [ { + "refresh_pattern": "\\(\\k\\+\\)$", "command": "html-languageserver", "requires": [ "npm" @@ -345,7 +346,7 @@ ], "ps1": [ { - "asyncomplete-refresh-pattern": "\\(\\$\\k*$\\|\\k\\+$\\)", + "refresh_pattern": "\\(\\$\\k*$\\|\\k\\+$\\)", "command": "powershell-languageserver", "requires": [ "pwsh" @@ -401,7 +402,7 @@ ], "ruby": [ { - "asyncomplete-refresh-pattern": "\\(\\$\\k*$\\|\\k\\+$\\)", + "refresh_pattern": "\\(\\$\\k*$\\|\\k\\+$\\)", "command": "solargraph", "requires": [ "gem" diff --git a/settings/html-languageserver.vim b/settings/html-languageserver.vim index 7855505..3cbd485 100644 --- a/settings/html-languageserver.vim +++ b/settings/html-languageserver.vim @@ -7,7 +7,7 @@ augroup vimlsp_settings_html_languageserver \ 'initialization_options': lsp_settings#get('html-languageserver', 'initialization_options', {'embeddedLanguages': {'css': v:true, 'javascript': v:true}}), \ 'whitelist': lsp_settings#get('html-languageserver', 'whitelist', ['html']), \ 'blacklist': lsp_settings#get('html-languageserver', 'blacklist', []), - \ 'config': lsp_settings#get('html-languageserver', 'config', {}), + \ 'config': lsp_settings#get('html-languageserver', 'config', {'typed_pattern': '/$\|\k\+$'}), \ 'workspace_config': lsp_settings#get('html-languageserver', 'workspace_config', {}), \ } augroup END |