Looking for a quick script solution

Gordon Marx gcmarx-Re5JQEeQqe8AvxtiuMwx3w at public.gmane.org
Thu Jun 25 23:03:57 EDT 2009


On Thu, Jun 25, 2009 at 10:33 PM, Richard Pieri<richard.pieri-Re5JQEeQqe8AvxtiuMwx3w at public.gmane.org> wrote:
> This finds all files in the current directory (.) but no deeper than
> the current directory (-depth 1) that match "*.gz" and execs gunzip on
> each one.

That's actually the behavior of find's -exec option. xargs is smarter
than that -- it executes command lines that are as near as possible to
the maximum length each time.

Gordon





More information about the Discuss mailing list