[...] Unix never ever decided what to do with a file
by its
extension but t does by its magic number [...]
Unix traditionally *doesn't* do
that either.
How do you think an unix shell is starting an excecutable file and
trough wich mechanism it knows what todo with an perl script, an
shell script, an C-shell scipt, and different kinds of executable
binary formats? It looks in the file for its header and is starting
the correct command interpreter for running that file or set up the
environment for executing a binary executable.
In unix a shell is doing this,
Actually, in the Unices I know well enough to know where that is done,
it's the kernel that does that, not the shell.
As for the whole "determine what to do based on content" idea, it's a
reasonable default, but it really needs to be overridable. To pick the
example that coems to mind most readily, I have not infrequently wanted
to take a file and print it twice, once treating it as text and once
treating it as PostScript code. (PostScript code can be, and often is,
plain text.)
I usually have to end up running it through a text-to-PS filter because
the printing subsystem insists on treating everything that looks enough
like PostScript as PostScript. :(
/~\ The ASCII Mouse
\ / Ribbon Campaign
X Against HTML mouse at
rodents-montreal.org
/ \ Email! 7D C8 61 52 5D E7 2D 39 4E F1 31 3E E8 B3 27 4B