sponsor Vim development Vim logo Vim Book Ad

MUcomplete : Chained (fallback) completion that works the way you want!

 script karma  Rating 29/10, Downloaded by 583    Comments, bugs, improvements  Vim wiki

created by
Lifepillar
 
script type
utility
 
description
GitHub page: https://github.com/lifepillar/vim-mucomplete

Can't stand the dozen of MB of YouCompleteMe? Can't figure out the correct settings to tame NeoComplete? D'you think AutoComplPop is an old fashioned fusion group and Supertab a movie hero for children?

With less code than documentation, µcomplete may be the minimalistic autocompletion plugin you were looking for!

MUcomplete is an implementation of chained (fallback) completion, whereby several completion methods are attempted one after another until a result is returned. MUcomplete brings Vim completion down to earth again.

Under the hood, µcomplete does nothing more than typing some completion mappings for you, either when you press <tab>/<s-tab> or automatically while you are typing. You choose which completion methods to use and in which order, and µcomplete does the rest. It does no caching, no asynchronous computation, no intelligent guessing. It just makes use of core Vim features.

Mandatory Vim settings:

    set completeopt+=menuone

For automatic completion, you also need to put these in your vimrc:

    inoremap <expr> <c-e> mucomplete#popup_exit("\<c-e>")
    inoremap <expr> <c-y> mucomplete#popup_exit("\<c-y>")
    inoremap <expr>  <cr> mucomplete#popup_exit("\<cr>")

and at least one of the following (choose the combination that best fits your taste):

    set completeopt+=noselect
    set completeopt+=noinsert

Other recommended settings:

    set shortmess+=c   " Shut off completion messages
    set belloff+=ctrlg " If Vim beeps during completion

No other configuration is needed. Just start pressing <tab> or <s-tab> to complete a word. If you want to enable automatic completion at startup, put

    let g:mucomplete#enable_auto_at_startup = 1

in your .vimrc. Automatic completion may be enabled and disabled at any time with :MUcompleteAutoToggle.

When the pop-up menu is visible, you may cycle back and forth through the completion methods in the current completion chain by pressing <c-h> and <c-j>, respectively.

MUcomplete is fully customizable. See :help mucomplete.txt for detailed documentation.

Important: by itself, µcomplete does not provide any “intellisense”/semantic completion. If you want that, you also need to install suitable omni completion plugins for the languages you are using.
 
install details
 

rate this script Life Changing Helpful Unfulfilling 
script versions (upload new version)

Click on the package to download.

package script version date Vim version user release notes
vim-mucomplete-1.0.0rc1.tar.gz 1.0.0rc1 2017-04-21 7.2 Lifepillar MUcomplete becomes even better and goes 1.0! The autocompletion mechanism is now based on a synergy between InsertCharPre and TextChangedI for a better user experience. Besides, a couple of minor bug fixes and some code refactoring.
vim-mucomplete-1.0.0b3.tar.gz 1.0.0.0b3 2017-04-19 7.2 Lifepillar MUcomplete becomes even better and goes 1.0! Autocompletion is now based on InsertCharPre instead of TextChangedI. CompleteDone is not used any longer. Removed g:mucomplete#trigger_auto_pattern: use g:mucomplete#can_complete instead.
vim-mucomplete-1.0.0b2.tar.gz 1.0.0b2 2017-04-18 7.2 Lifepillar Fixed a critical regression.
MUcomplete becomes even better and goes 1.0! With better autocompletion, other new cool features and bug fixes.
vim-mucomplete-1.0.0b1.tar.gz 1.0.0b1 2017-04-17 7.2 Lifepillar MUcomplete becomes even better and goes 1.0! Much improved autocompletion experience: the pop-up menu does not go on and off on alternating keys any longer! Make <tab> move in the pop-up menu from top to bottom or from bottom to top on a per-completion type basis! Allow path completion relative to the directory of the current buffer! Use 'path' completion by default. Et cetera… All of this in the same amount of code! Please check the Readme and the documentation.
vim-mucomplete-0.5.0.tar.gz 0.5.0 2016-12-15 7.2 Lifepillar Too many changes to list here. Some highlights: improved spelling method, with new options; ignore `noselect` for manual completion (except for spelling methods); use <c-j> instead of <c-l> as a right cycling key, for better compatibility; new setting to exit ctrl-x submode (mucomplete#exit_ctrlx_keys has been removed) and new default value (`<c-g><c-g>`); bug fixes in 'cmd' and 'ulti' methods, and other critical and less critical bug fixes. Kudos to bug hunter LacyGoIll for reporting and solving several issues!
vim-mucomplete-0.4.3.tar.gz 0.4.3 2016-12-04 7.2 Lifepillar Improved documentation.
vim-mucomplete-0.4.2.tar.gz 0.4.2 2016-11-26 7.2 Lifepillar Improved documentation.
vim-mucomplete-0.4.1.tar.gz 0.4.1 2016-11-19 7.2 Lifepillar Added flag variable that tells whether completion is initiated automatically or by pressing a key. Fixed a bug in 'line' completion. Expanded documentation.
vim-mucomplete-0.4.0.tar.gz 0.4.0 2016-11-15 7.2 Lifepillar - New 'path' completion method that works similar to YouCompleteMe.
- New 'uspl' spelling suggestion method, which acts only on the word in front of the cursor.
- Several bug fixes.
- Compatible with Vim 7.2 or later.
vim-mucomplete-0.3.1.tar.gz 0.3.1 2016-11-04 7.3 Lifepillar Respect completeopt's settings, including noinsert and noselect.
vim-mucomplete-0.3.0.tar.gz 0.3.0 2016-11-02 7.3 Lifepillar Added the ability to cycle back and forth through completion methods while the pop-up is visible.
Improved compatibility with older Vim. Other minor additions and a few code optimizations.
vim-mucomplete-0.2.0.tar.gz 0.2.0 2016-10-28 7.4 Lifepillar Improve compatibility with older Vim. Add more options. Add support for suggesting UltiSnips snippets. Other minor fixes.
vim-mucomplete-0.1.2.tar.gz 0.1.2 2016-10-26 8.0 Lifepillar Fixed a bug causing completion methods to be skipped even when they return results.
vim-mucomplete-0.1.1.tar.gz 0.1.1 2016-10-24 8.0 Lifepillar Fix a bug preventing tab completion to display the popup menu.
vim-mucomplete-0.1.0.tar 0.1.0 2016-10-23 8.0 Lifepillar Initial upload
ip used for rating: 54.161.108.158

If you have questions or remarks about this site, visit the vimonline development pages. Please use this site responsibly.
Questions about Vim should go to the maillist. Help Bram help Uganda.
   
SourceForge.net Logo