ordering in linux 'ls -la'

From: Digital Puer (digital_puer_at_hotjail.comet)
Date: 11/30/03


Date: Sat, 29 Nov 2003 15:14:03 -0800

The 'ls -la' command is returning a different ordering of files
between Solaris and Linux with respect to dot-files.

Under Solaris (which I'm accustomed to using), ls -la returns
the following:

drwx------ 2 dude dude 512 Nov 29 15:02 .
drwxrwxrwt 15 root root 512 Nov 28 14:32 ..
-rw-r--r-- 1 dude dude 0 Nov 29 15:02 .foo
-rw-r--r-- 1 dude dude 0 Nov 29 15:02 boo
-rw-r--r-- 1 dude dude 0 Nov 29 15:02 goo

Under Red Hat Linux, it returns the following (note the intermixing
of dot-files with regular files):

drwxrwxr-x 2 dude dude 4096 Nov 29 15:03 .
drwx------ 36 dude dude 4096 Nov 29 14:59 ..
-rw-rw-r-- 1 dude dude 0 Nov 29 15:03 boo
-rw-rw-r-- 1 dude dude 0 Nov 29 15:02 .foo
-rw-rw-r-- 1 dude dude 0 Nov 29 15:03 goo

Can someone tell me how to set the output of 'ls -la' under
Linux to have the same ordering as under Solaris? I checked
all the flags to Linux's ls, but I could not find the appropriate
solution. Thanks for any help.


Quantcast