Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

When opening another file in my project using :e path/to/filTAB, vim will auto-complete the filename with all matching files, in alphabetical order. However, my project is full of .coffee, .litcoffee, .js and .map files.

How do I tell vim not to auto-complete the .js and .map files?

share|improve this question
up vote 5 down vote accepted

Wildmenu is the component, if you want to call it that, responsible for the files you open with :e. You can set ignore rules for it easily in your .vimrc using

set wildignore+=*.filetype

So say you want to ignore your filetypes, it would be:

set wildignore+=*.js,*.map

There's a great overview here. I would recommend you to write a specific config file for only this project, and load it when you're working on said project. In this way, vim will only ignore these files when you want it to, and not always.

share|improve this answer
I actually had to +=*.js,*.map to wildignore, but thangs! – Attila O. Jun 6 '13 at 11:55
Absolutely right, typo in my example. Corrected. – SBI Jun 6 '13 at 13:06

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .