5/8 On the linux ls discussion from the other day, this is my take:
Using/learning linux specific flags is all fine and good, and
adding new features to old tools is too, but when I have to
switch between 5 different OSes in a given day, it's simply a
waste of my time. There are many ways to solve a given problem.
Linux's solution always seems to be "add another flag". If you're
a Linux only shop, have at it. Learn all the little idiosyncracies
of your favorite flavor. But god help you when you get an HPUX
box thrown at you. --scotsman
\_ Relax, you'll live longer. Learn how to use alias and edit
the default profile. -williamc
\_ You miss the point entirely. Sometimes this is not an option.
If you're not a sysadmin then this discussion doesn't matter.
I'm talking about efficiency in work situations. --scotsman
\_ Compare:
ls -S 6 keypresses
ls -l|sort -n +4 18 keypresses
Is that something you want to type for such a simple user task?
It's just arrogant and silly to not do it, for something so
common and easy. Including the date or name sort is no more valid.
On soda there is "dir" which has it. Go study UI principles.
\_ This is the stupidest thing I've seen on motd in weeks.
Comparing the number of keypresses? Christ, man, it's about
getting the job done as effectively as possible. When you're
down to counting keystrokes, you've lost touch with reality about
what constitutes a sane metric for efficiency.
\_ effective? What's more effective about piping to sort? it's
more limiting, and more obscure. And yes, it takes more effort
to type that shit out. It's not about "efficiency" so much as
simple ease of use and consistency. That's reality. Not some
elitist ubergeek deciding to simply put a note in the man page
about how it's not needed. Obviously the fact that it's in
the man page means it's a desired feature.
\_ What's more effective than piping it to sort? Could you
have missed the point any more? Jeeesus.
\_ Ever stop to consider you're the one missing the point?
\_ Yes, but I'm not. Have a cookie.
\_ It's not more obscure. In fact it's less obscure and more
consistent unless you're immersed in Linux. Why is this
point so hard to grasp? --scotsman
\_ Forget the status quo, it's more obscure from a
usability standpoint. I have to know about the sort
command and that I have to do ls -l and sort on that
4th column but oh I might need the -n for numeric
vs. lexical sorting. Honestly this is really really
basic. It's not consistent that there is built-in
date sort, or alphabetical sort, and not size sort,
\_ In 10 years, I think there still be be Windows and Mac OS.
the only other basic file property. It's not consistent
that I need the long detailed listing when with a
builtin it could just work like normal. And it's just
plain inconvenient. You don't have to be "immersed
in Linux" to see that. I barely even use Linux. It's
just common sense and refusing to worship status quo.
Oh and I'm just arguing about what's correct, not
the "least-common-denominator" factor of working with
15 different unixes.
\_ Did it ever occur to you that sometimes the status
quo *is* the status quo because it has worked well
since before you were born and is just plain better?
\_ The extension of the point is that when you have
learned to use sort appropriately you can then
apply it in other cases. Read the philosophy of
UNIX page partha posted below. If you don't work
on 15 different unixes then, as I said above, this
discussion doesn't apply to you. If I get pulled in
to help out a client to save a $100k sale, I have
to get the job done quickly. Knowing the least-
common-denominator allows me to get up to speed
quickly. It's not worshiping anything. It's doing
my job well. --scotsman
\_ you know, it's possible to know how to use
"sort," and still support the idea of
internalizing functions in Unix utilities in
appropriate ways. You don't need "find -nouser"
to be able to find files without a legitimate
owner, but it's clearly a functional enhancement
to the original "find" functionality. As for
the "philosophy of Unix", don't you think it's
a bit ironic that the person posting it is
mr. emacs? -tom
\_ Either you're following the unix philosophy or
you're trying to circumvent and short cut it
and that way leads to madness and windows
methodology and chaos.
\_ well, clearly there is a "merit of having -S in
ls" discussion going on, although the thread
didn't start with that. But it's devolved into
reiterating already-stated points.
\_ So rather than being obtuse you're merely off-
topic?
\_ Obviously? So if I write a man page that says you don't
understand the core concept of unix utilities then it
becomes obvious? Sigh, I shall explain for the unwashed:
the core concept you're missing is that unix is about
having lots of little utilities that each do one thing
really well. You create a stream of data from little
util to the next via pipes and out pops the right thing
at the other end. I know 'ls' and 'sort'. I know I can
pipe from one to other. I know this works on every *nix
system I might ever touch. This is called portability.
Linux is the bastard child here, not the non-Linux real
unixen you're deriding. Linux is following the Windows
style of over loading programs with things that seem neat
at the time but turn into bloated crap later. I like Unix.
I accept Windows. I do not want my Unix bloated up into a
half assed Windows a la Linux. Simplicity, son. KISS.
\_ you dolt, yes I know about all that shit. "son". my
point is simply about the usability issue. I don't care
what other unices are doing, I'm saying that they should
do this. Whoever wrote that man page obviously knew
about the option and knew there were poeple wanting it.
-S is not "bloated crap" any more than -t or -r. ls
is probably the most common command users run. Listing
files is what ls does, it should "do it well". I could
write a man page that says vi is unnecessary because
you have ED IS THE STANDARD!
\_ Sorting on a date with sort is not the same as
sorting on an integer such as size. Please explain
in what way I am a dolt. Is it that I read your mind
and understand what you don't understand to such a
degree that you have nothing left to say but insult
me? If that is the case, then yes, I am a dolt.
\_ It sure is the same, son. Sorting on a date isn't
algorithmically identical, so what, irrelevant.
You're ignoring the big picture. I'm done arguing
for today though. Btw ls could easily output the
date in a sortable manner. Unix philosophy doesn't
require factoring everything into as many programs
as possible.
\_ alias ls-S "ls -l | sort -n +4"
now you can type "ls-S" in 5 keypresses! for common tasks, you
can make the number of required keystrokes arbitrarily short or
long. non-issue.
\_ duh. of course you can make an alias. totally beside the
point. of course you'd have to do more work to make it work
just like a real "ls -S" would.
\_ This is why after 10 more years, there will only be Linux
and nothing else, because the other OS are simply too arrogant
to do anything about it. Take for example the man pages on
Solaris, I mean how much effort does it take to make it so that
it will format according to your screen and does not produce
the stupid 24 line page header every page? Everytime I look at
the man page on Solaris I curse it. The linux one is so much
better. One reason why SunOS is fading.
\_ You know, I HATE working on Solaris. Nothing works the way
that I'm used to without aliasing everything. However, when
we were running our server on Solaris it never once crashed in
the entire time I was in charge of it. I can't say the same
for any of the Linux installs I've set up.
\_ In 10 years, I think there still will be Windows and Mac OS.
Your arguments for Linux and against other Unix OSs are the
the same as the arguments for Windows/Mac OS and against Linux.
Every time I read a man page I curse it. Hyperlinked help files
are so much better.
\_ personally, I find the statement "after 10 more years, there
will only be xxxxx and nothing else... " to be pretty
absurd in the context of any technological question.
\- the amount of wrongheadedness in this thread is amazing.
but rather than agrue, the youth ought to read ... --psb
http://www.faqs.org/docs/artu/ch01s06.html
\_ excellent. --scotsman
\_ Yes! Finally! This should be mandatory reading before
geting into core CS classes or getting a Soda account.
\_ In 10 more years Linux will 'rewl' because the man pages format
better than on Solaris? If that's the best you can come up with
then just stick with Windows and reboot a lot. |