From: noyd@u.washington.edu (Steve Jones)
Subject: Re: HELP with remove (rm)
Date: 1997/02/13 [thread overview]
Message-ID: <5e03i8$m6l@nntp1.u.washington.edu> (raw)
In-Reply-To: 33037089.68BD@pangea.stanford.edu
In article <33037089.68BD@pangea.stanford.edu>,
Phil Farrell <farrell@pangea.stanford.edu> wrote:
>Achachila wrote:
>> Sorry but I am new to Digital Unix, could anyone tell me how can I rm
>> 1000 of files without getting Arg. list to long?
>> I need to rm something like *96*
>
>Try:
> find /directory-with-your-files -name "*96*" -exec rm {} \;
>This will traverse the directory tree and match and remove files
>one by one, rather than trying to make one giant command line
>listing all the files.
See also the "xargs" command for avoiding the limit on the
size of the argument list in your shell.
For example:
ls | grep 96 | xargs rm
--
--
Steven Jones
Computing & Communications 354843, University of Washington
E-mail: noyd@u.washington.edu Phone: (206) 543-5852
next prev parent reply other threads:[~1997-02-13 5:00 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
1997-02-11 5:00 HELP with remove (rm) Achachila
1997-02-13 5:00 ` Phil Farrell
1997-02-13 5:00 ` Steve Jones [this message]
1997-02-13 5:00 ` Lee Doolan
1997-02-14 5:00 ` Alex Nord
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox