Case sensitivity

Introduce yourself, create test postings or talk nonsense
Post Reply
GJones
Donor
Posts: 300
Joined: 22. Jul 2011, 23:27

Case sensitivity

Post by GJones »

... is IMO by far the most annoying thing about the UNIX command line. Fortunately for those of us still using bash, there is an easy solution.

Code: Select all

set completion-ignore-case on
Put that in ~/.inputrc for per-user configuration, or /etc/inputrc to apply it system-wide. Next time you open a bash prompt, hitting tab will complete to the nearest possible word regardless of case, e.g. "~/proj" -> "~/Projects/". Since I started using case-insensitive completion, I have pretty much abandoned graphical file managers - the CLI is that much faster.
kcirick
Posts: 41
Joined: 13. Dec 2012, 05:34

Re: Case sensitivity

Post by kcirick »

Thanks for the tip!

I really don't have issues with case sensitivity when navigating through my files. I do use thunar for when I want to open certain media files using different applications. Do you have any cool tricks? For example, if I type in 'open file.pdf' will bring up evince (or other pdf viewer), and if I type 'open file.avi', it will bring up mplayer, etc...
Image
User avatar
mimosa
Salix Warrior
Posts: 3311
Joined: 25. May 2010, 17:02
Contact:

Re: Case sensitivity

Post by mimosa »

MPlayer is only case-sensitive in slapt-get. Thx gd. :p
User avatar
gapan
Salix Wizard
Posts: 6241
Joined: 6. Jun 2009, 17:40

Re: Case sensitivity

Post by gapan »

kcirick wrote:Thanks for the tip!

I really don't have issues with case sensitivity when navigating through my files. I do use thunar for when I want to open certain media files using different applications. Do you have any cool tricks? For example, if I type in 'open file.pdf' will bring up evince (or other pdf viewer), and if I type 'open file.avi', it will bring up mplayer, etc...
You mean like:

Code: Select all

xdg-open file.pdf
or

Code: Select all

xdg-open file.avi
or whatever filetype you want really...

You can even alias xdg-open to open...
Image
Image
GJones
Donor
Posts: 300
Joined: 22. Jul 2011, 23:27

Re: Case sensitivity

Post by GJones »

For that you probably want to use perl-File-MimeInfo via the mimeopen command.

Edit: perl-File-MimeInfo is bugged ATM, just a second...
kcirick
Posts: 41
Joined: 13. Dec 2012, 05:34

Re: Case sensitivity

Post by kcirick »

gapan wrote:
kcirick wrote:Thanks for the tip!

I really don't have issues with case sensitivity when navigating through my files. I do use thunar for when I want to open certain media files using different applications. Do you have any cool tricks? For example, if I type in 'open file.pdf' will bring up evince (or other pdf viewer), and if I type 'open file.avi', it will bring up mplayer, etc...
You mean like:

Code: Select all

xdg-open file.pdf
or

Code: Select all

xdg-open file.avi
or whatever filetype you want really...

You can even alias xdg-open to open...
Yup. Exactly what I was looking for. Thanks
Image
Post Reply