[Fix] Check that merlin_home is present in autoload/merlin.vim #665
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hey guys! First of all thanks for Merlin. The badassery it brings to writing Ocaml in vim is unrivalled.
From a fresh start on macOS 10.12.5, with vim 8.0.1666, I got this from the get go:
Apparently the code initially generated by
opam user-setup install
on myvimrc
didn't set up the right globals? It seems the code is looking fors:c.merlin_home
(https://github.com/ocaml/merlin/blob/master/vim/merlin/autoload/merlin.vim#L676) which in turn comes fromg:merlin
(https://github.com/ocaml/merlin/blob/master/vim/merlin/autoload/merlin.vim#L1), which wasn't set anywhere.So after manually adding it to my already existing
ftplugin/ocaml.vim
, everything started to work again.Here's my 2 cents, checking that
s:c.merlin_home
actually is set before trying to use it.If there's anything else I need to do, or if you think there's a better way of handling this, I'm happy to hear out and put some more work in it 👍