Friday, January 14, 2011

Annoying Defaults

I've said it many times before and I'm sure I'll say it many times in the future: every operating system sucks. If you haven't found what it is that makes your particular-favorite suck, you haven't been using it long enough, hard enough or both (either that, or you're just deluding yourself).

One of my co-workers is a Windows geek (well, it's what he's most comfortable using, any way). He likes to make cracks about Linux as though it will insult me, somehow. I'm not sure why he thinks this will work. I mean, it's not like I wrote Linux, so, I don't have any personal stake in it. But, whatever. Hell, I'll be the person at the head of the line to recite my own list of grievances about it. I'd be the first person at the head of the line bitching about pretty much any piece of technology I've used more than casually.

At any rate: Linux...

There are quite a number of things that I hate about Linux. In fact, when the previously-mentioned co-worker said to me, "Linux sucks," I agreed. I did, however, also say, "but it still sucks less than Windows."

One of the things I have always hated about Linux is its default shell. AT&T-derived UNIX operating systems use the old, bog-standard Bourne shell (/bin/sh) as their default shell. The BSDs brought us the C-Shell (/bin/csh) as the default shell (though, some derivatives later shifted to the TENEX C-Shell - /bin/tcsh). IBM and SGI decided that their OSes, being more up to date derivatives of the AT&T UNIX should have a more modern default shell. Both chose to have Korn Shell (/bin/ksh) as their default login shell.

I used to work for SGI. I've done a lot of work on IBM UNIX systems (AIX). So, I got used to having KSH as my default login shell. I also do a lot of scripting. KSH supports standard Bourne shell syntax but adds a number of useful extensions - in particular, I like the internal function construct. So, at this point in my UNIX-using career, I prefer KSH to all other shells.

Linux, unfortunately, being a "UNIX work-alike", has a different default shell than all other UNIX(y) operating systems. All of the previously-mentioned shells used to not be fully "in the public domain". So, when they needed an interactive shell, the Linux-coders came up with the Bourne Again Shell (or 'BASH'). It's kind of a hodgepodge of all of the shells that had existed when BASH was first created. It offers a lot of featuer-commonality with the other shells, plus some of its own tricks. Unfortunately, as with any "be all" solution, it's a giant ball of compromise rather than being particularly optimized.

Any way, none of that is exactly germane. The particular beef I have with Linux is the use of color in many applications and tools outputs. Where I particularly see it is in the output of the directory listing command, `ls`. In most of the Linux distributions I've used, the default login preferences specification turns on the use of color in the out put of `ls`. The output is what I refer to as "angry fruit salad." It's lots of garish shades of yellow, red, green and blue. It's rather hard to read.

Angry Fruit Salad
If I have rights to disable it, I immediately change the login profile to get rid of it. Unfortunately, it's usually the case that I don't have the rights to permanently disable it. So, the best I can do is, immediately upon login, is do `unalias ls`.

But... I shouldn't have to! Criminy: whose brilliant idea was it to make the BASH default alias for `ls`  display in color???

No comments:

Post a Comment