aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGuangxiong Lin <[email protected]>2023-10-21 08:34:35 +0800
committerGuangxiong Lin <[email protected]>2023-10-21 08:34:35 +0800
commit11d9d45594abd2c9d75d6bb98d1ed3a25e461826 (patch)
tree8b40b14e6d8218cb5d90f3296f5de5d88c4df6f2
parent0ccfe68e97ad3f05ba6d36d2568c88a7d8d8f15b (diff)
downloaddotfiles-11d9d45594abd2c9d75d6bb98d1ed3a25e461826.tar.gz
dotfiles-11d9d45594abd2c9d75d6bb98d1ed3a25e461826.tar.bz2
dotfiles-11d9d45594abd2c9d75d6bb98d1ed3a25e461826.zip
Remove the default trigger of mucomplete.
The omnifunc sometimes is triggered unexpectedly, causing the vim to freeze for a long time. For example, triggered in a large yaml file.
-rw-r--r--.vim/after/plugin/mucomplete.vim5
1 files changed, 2 insertions, 3 deletions
diff --git a/.vim/after/plugin/mucomplete.vim b/.vim/after/plugin/mucomplete.vim
index b955c14..3efbcbe 100644
--- a/.vim/after/plugin/mucomplete.vim
+++ b/.vim/after/plugin/mucomplete.vim
@@ -6,7 +6,6 @@ let g:mucomplete#always_use_completeopt = 1
let g:mucomplete#can_complete = {}
let s:default_cond = { t -> strlen(&omnifunc) > 0 && t =~# '\%(\.\)$' }
-let g:mucomplete#can_complete.default = { 'omni': s:default_cond }
let g:mucomplete#chains = {}
let g:mucomplete#chains.default =
\ [ 'ulti', 'user', 'omni', 'c-p', 'path' ]
@@ -19,10 +18,10 @@ let s:cpp_cond = { t -> strlen(&omnifunc) > 0 && t =~# '\%(\.\|->\|::\)$' }
let g:mucomplete#can_complete.cpp = { 'omni': s:cpp_cond }
let g:mucomplete#can_complete.objcpp = { 'omni': s:cpp_cond }
let g:mucomplete#can_complete.cuda = { 'omni': s:cpp_cond }
+let g:mucomplete#can_complete.ruby = { 'omni': s:cpp_cond }
+let g:mucomplete#can_complete.rust = { 'omni': s:cpp_cond }
let s:ledger_cond = { t -> t =~# '\%(:\)$' }
let g:mucomplete#can_complete.ledger = { 'omni': s:ledger_cond }
-let g:mucomplete#can_complete.ruby = { 'omni': s:cpp_cond }
-
packadd vim-mucomplete