Re: trouble with deleting files on unix

From: Date: Thu, 14 Mar 2002 12:18:43 +0000
Subject: Re: trouble with deleting files on unix
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-88478@lists.php.net to get a copy of this message
On Thursday 14 March 2002 20:01, andy wrote: > Hi there, > > I know this is not a unix board, but maybe someone had to cope with the > same problem. > > I have a couple of wired filenames matching all this pattern .jpeg: > > How can I delete all files matching this pattern recursive in all > directories? > I tryed : rm -r test *.jpeg:* > > But this only deletes the files in the test dir not in the test/subdir try: find /path/to/dir -iname "*.jpeg" -exec ls -al {} \; If the files listed are the ones you want to delete then find /path/to/dir -iname "*.jpeg" -exec rm {} \; -- Jason Wong -> Gremlins Associates -> www.gremlins.com.hk /* The cost of living is going up, and the chance of living is going down. */

« previous php.general (#88478) next »