Re: Sort files by filename

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

 



Les wrote:
	Using C, you could open the directory, sort the list, compare for a
desired sequence from a starting value to an ending value and pass out a
list of missing files, and it would take only milliseconds, primarily
limited by disk access speed.

Milliseconds aren't so hard to match these days. Let's try my 'compare to list' shell approach:

# time ls * |comm -13 - ../list
5
6

real    0m0.007s
user    0m0.002s
sys     0m0.007s

Note that it is dominated by the system time anyway - although you have to wonder about the math there - maybe both processors get counted.

--
  Les Mikesell
   lesmikesell@xxxxxxxxx


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux