[wplug] Question vaguely involving vfat

Tom Rhodes trhodes at FreeBSD.org
Sun Jun 3 16:15:31 EDT 2007


On Sun, 3 Jun 2007 15:47:59 -0400
"Michael H. Semcheski" <mhsemcheski at gmail.com> wrote:

> > Like, in order of file name found?  Can't you just rename the
> > files to appear in order?
> 
> I think what she's saying is...
> 
> The -f option of ls shows files in unsorted order.  But unsorted is
> not random.  Typing 'ls -fil' shows the same results each time.  And
> copying a file or moving a file out of the directory in question does
> not change the order of other entries relative to each other.
> 
> So, the question is, how to affect this 'natural order'?

I'm not sure in this situation, but "natural order" in many
cases (at least with UFS/FFS) seems to be the order in which
files are created on the device.

This works for file copies as well.  Again, on my system.

I've tested this (not thoroughly) on my local system by
creating several files.  Regular "ls" seems to sort A-Za-z like
you'd expect but -f always seems to show them in order of
creation "directory inventory" I believe is the original term
used.

An interesting thing here, again with my really quick tests,
doing a cat on a directory lists:
. .. CVS bin etc COPYRIGHT ...

which is the same order "-f" prints the listings.  Perhaps
this is what she needs to do, copy/move the files in place
in the order she want's them seen?  Can't hurt to try, and
in my few second testing, it seems to do what she wants.

-- 
Tom Rhodes


More information about the wplug mailing list