Re: du Weirdness - how is this possible

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 14/3/18 7:42 am, Rick Stevens wrote:
On 03/13/2018 01:19 PM, Stephen Morris wrote:
On 13/3/18 9:05 am, Ed Greshko wrote:
On 03/13/18 05:47, Ed Greshko wrote:
On 03/13/18 05:20, Stephen Morris wrote:
Thanks Ed, I'll check the doco out, I was just expecting the command
to do exactly
what the help info said, output the information for all files, not
just a subset.
It *does* do exactly what the man page says.  You just have to
understand the
"context" in which it is saying it.

Let me complete my thought.  Even take the "ls" command as an example.

[egreshko@meimei test-dir]$ ls
test  test1  test2

[egreshko@meimei test-dir]$ ls -a
.  ..  test  test1  test2  .test3  .test4  .test5

[egreshko@meimei test-dir]$ ls *
test  test1  test2

[egreshko@meimei test-dir]$ shopt -s dotglob

[egreshko@meimei test-dir]$ ls *
test  test1  test2  .test3  .test4  .test5

Oh, when it comes to ls, I've been gently reminded about -A

[egreshko@meimei test-dir]$ ls -A
test  test1  test2  .test3  .test4  .test5
Thanks Ed, I knew about the differences between the -a and -A on ls, and
having had a look at the --help for ls and du again, I can see the
subtle difference between the -a parameters on both commands. It just
seems counter intuitive to me to have to issue another command (even if
one knows of its existence) to get a command to function "properly".
I COULD drive a dump truck or a sedan to work every day. If I were in
the construction business, the dump truck might make sense. I'm not, so
I drive a sedan. Both would get me to the job, it's just which is more
"appropriate" that's at issue.

"ls" lists the characteristics of files, while "du" displays disk usage.
While they are related, they are, none the less, different things. It's
up to you, the user, to use the appropriate command for what you want.

The alternative is one program that tries to do EVERYTHING. That's been
tried. It's called "Windows Explorer" and we all know what an atrocity
that turned out to be!

This is true, but "du" is extremely useful, when it provides a total of the space occupied by directories, to determine where space hogs are and why.


regards,

Steve


----------------------------------------------------------------------
- Rick Stevens, Systems Engineer, AllDigital    ricks@xxxxxxxxxxxxxx -
- AIM/Skype: therps2        ICQ: 22643734            Yahoo: origrps2 -
-                                                                    -
- The difference between nerds and geeks?  Nerds are socially inept  -
-    and are painfully aware of that.  Geeks couldn't care less.     -
----------------------------------------------------------------------
_______________________________________________
users mailing list -- users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to users-leave@xxxxxxxxxxxxxxxxxxxxxxx
_______________________________________________
users mailing list -- users@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to users-leave@xxxxxxxxxxxxxxxxxxxxxxx



[Index of Archives]     [Older Fedora Users]     [Fedora Announce]     [Fedora Package Announce]     [EPEL Announce]     [EPEL Devel]     [Fedora Magazine]     [Fedora Summer Coding]     [Fedora Laptop]     [Fedora Cloud]     [Fedora Advisory Board]     [Fedora Education]     [Fedora Security]     [Fedora Scitech]     [Fedora Robotics]     [Fedora Infrastructure]     [Fedora Websites]     [Anaconda Devel]     [Fedora Devel Java]     [Fedora Desktop]     [Fedora Fonts]     [Fedora Marketing]     [Fedora Management Tools]     [Fedora Mentors]     [Fedora Package Review]     [Fedora R Devel]     [Fedora PHP Devel]     [Kickstart]     [Fedora Music]     [Fedora Packaging]     [Fedora SELinux]     [Fedora Legal]     [Fedora Kernel]     [Fedora OCaml]     [Coolkey]     [Virtualization Tools]     [ET Management Tools]     [Yum Users]     [Yosemite News]     [Gnome Users]     [KDE Users]     [Fedora Art]     [Fedora Docs]     [Fedora Sparc]     [Libvirt Users]     [Fedora ARM]

  Powered by Linux