case insensitive tab-completion or wild expansion

To let wildcard expansion case insensitive, enable this in bashrc

shopt -s nocaseglob

To let tab-completion case insensitive, you can bind the completion-ignore-case option for bash:

bind `echo set completion-ignore-case on`

This will be effective immediately.

Or add this in inputrc for readline;

$ echo 'set completion-ignore-case On' >> ~/.inputrc

Include the system inputrc file:

include /etc/inputrc

To show all binds:

bind -p

To let bash recognizes spelling mistakes, add this in ~/.bashrc:

shopt -s cdspell

For tcsh / zsh users:

set complete enhance



Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s