LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 11-27-2007, 11:14 AM   #16
forrestt
Senior Member
 
Registered: Mar 2004
Location: Cary, NC, USA
Distribution: Fedora, Kubuntu, RedHat, CentOS, SuSe
Posts: 1,288

Rep: Reputation: 99

nx500, you're right, I also had to escape the ';'. I guess I copied the wrong line from my history and then forgot later that I had had to escape that as well. However, the quotes around the swirly brackets aren't to escape the brackets, they are to make the filenames with spaces get passed to the rm command as one parameter (i.e., the quotes get passed to the command as well and you get "file name" instead of file name).

HTH

Forrest
 
Old 09-03-2008, 07:41 PM   #17
Huike
LQ Newbie
 
Registered: Sep 2008
Posts: 1

Rep: Reputation: 0
I was trying to do the same thing and found this post. After some play I found the solution as below:

find "c:\temp 1" -name "*.log" -mtime +6 -exec rm \"{""}\" ;

At least it worked for me in Windows XP SP3. Hope it will help.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
script to auto delete files older than X days nocnoc Programming 17 12-06-2006 09:30 AM
find and delete files - stupid question though smshuja Linux - Newbie 5 12-29-2005 02:21 AM
delete files older than 30 days using cronjob latheesan Linux - Newbie 5 06-14-2005 03:40 PM
delete files in server that is older than 30 days using cronjob latheesan *BSD 2 06-14-2005 01:37 PM
vi command to find and delete all lines beginning with a character geomatt Linux - Software 8 12-20-2004 04:30 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 01:13 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration