Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

At the moment I'm writing a document where need to use a lot of acronyms, technical language, and non German words.

Now I was thinking if I could create a spelling file (tech_speak) which checks for this technical language so I can use the following vim command

:set spelllang=de,tech_speak spell

How could this be done?

share|improve this question

2 Answers 2

up vote 5 down vote accepted

The 'spellfile' option is what you're looking for:

:set spellfile=~/.vim/spell/techspeak.utf-8.add

Note: Avoid special characters like _; as it separates the region name in Vim.

You can then add your custom words to it with zg. You don't even need to add anything to 'spelllang'; those additions will be considered automatically.

share|improve this answer
    
Yeah this looks good but, when I use zg vim throws "E751: Output file name must not have region name" at me. –  Raphael Ahrens Aug 5 '13 at 10:01
    
Ah I needed to remove the _ so :set spellfile=~/.vim/spell/techspeak.utf-8.add works. Thanks! –  Raphael Ahrens Aug 5 '13 at 10:03
    
You're right; it's best to avoid such characters; I've edited my answer. –  Ingo Karkat Aug 5 '13 at 10:22
:help spell-mkspell

is what you are looking for.

share|improve this answer
    
Please correct me if I'm wrong. But as far as I had read this I need an existing dictionary file. But I want to make a new language file which I can combine with my language. –  Raphael Ahrens Aug 5 '13 at 9:59
1  
A dictionary file can be a simple word list. –  n.m. Aug 5 '13 at 10:16

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.