[LUAU] How do you delete over 500,000 files in a directory
Hawaii Linux Institute
wp at HawaiiLinux.us
Thu Nov 3 15:14:30 PST 2005
Jim Thompson wrote:
> or cut down on the amount of globbing that the shell does in any one
> pass.
> If all the files end in a number, (and the numbers are well-distributed)
>
> #!/bin/bash
> i="0"
> while [ $i -le 9 ]
> do
> echo mgetty*$i | xargs rm -f
> i=$[$i+1]
> done
>
Didn't realize you already answered the question Jim. Wayne
More information about the LUAU
mailing list