Ignore types of files when you tab from the command line

5

1

One of the nice features of vim is that you can ask it to ignore certain types of files when you hit tab by using the following command in vimrc:

set wildignore+=*.hi,*.pyc,*.o

Is there a similar setting for bash so I can ignore types of files when I tab in the command line?

Kevin Burke

Posted 2011-03-04T04:24:11.780

Reputation: 809

Answers

8

The bash variable you are looking for is FIGNORE, for your example

export FIGNORE=$FIGNORE:.hi:.pyc:.o

I personally still cannot live without

export FIGNORE=$FIGNORE:CVS

Benjamin Bannier

Posted 2011-03-04T04:24:11.780

Reputation: 13 999

What is CVS? A filename or something with special meaning? – Frozen Flame – 2015-07-11T04:21:22.737

@FrozenFlame, CVS is the directory where the archaic version control system cvs (http://www.nongnu.org/cvs/) stores its control files. The example shows how FIGNORE may contain both file and directory patterns.

– Benjamin Bannier – 2015-07-11T10:17:15.660