How to make Vim download missing word lists


vim set spelllang in .vimrc

On start up, vim is supposed to offer to download missing word lists for spell checking, but sometimes, this is not the case (at least on my Ubuntu machine). This problem appears when you have set spell and set spelllang=<some language other than English> in your .vimrc. Instead of being helpful by offering to download the missing spellfiles, vim throws an error:

Warning: Cannot find word list "fr.utf-8.spl" or "fr.ascii.spl"

I worked around this problem by starting vim, ignoring the above warning message, running :set nospell, followed by :set spell, and then vim helpfully offers to download the missing word lists. Now I can check for my French spelling mistakes!

Note: I am not sure how this works because I found the solution by accident. I suspect that this problem is a bug in vim. It could also be that I do not understand vim well enough.