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

Re: bash script question



Kevin McKinley <ronin2@bellatlantic.net> writes:

> On 05 May 2003 17:19:04 +0100
> Oliver Elphick <olly@lfix.co.uk> wrote:
>
>> for f in `find . -type f`
>> do
...
>> done
>
> Can the "for" line be replaced with
>
> for f in *
>
> What would be the difference, except being simpler and not using find? :)

* includes all files and subdirectories in the current directory that
don't begin with a dot; the find invocation finds only files (not
subdirectories) in the current directory and all subdirectories
(recursively), regardless of their name.

-- 
David Maze         dmaze@debian.org      http://people.debian.org/~dmaze/
"Theoretical politics is interesting.  Politicking should be illegal."
	-- Abra Mitchell



Reply to: