Download your favorite Linux distribution at LQ ISO.
Go Back > Forums > Non-*NIX Forums > Programming
User Name
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.


  Search this Thread
Old 03-12-2005, 02:16 PM   #1
Registered: Dec 2003
Location: Canada
Distribution: Suse 10
Posts: 206

Rep: Reputation: 30
Remove folder and file


under linux (c programming)

i have this file


i would like to remove:

other folder can exist...

all folder and file after /led need to be erased

are there a way to remove all folder after led?

Old 03-12-2005, 03:12 PM   #2
Senior Member
Registered: Mar 2004
Distribution: Slackware
Posts: 4,617

Rep: Reputation: 137Reputation: 137
I would do :
find /opt/good/Ext5_Linux_RTU2/led -mindepth 2 -exec rm -rf {} \;
I did not read carefully " other folder can exist..."
This command would remove all contents of
/opt/good/Ext5_Linux_RTU2/led subdirectories

Could you ellaborate with " other folder can exist..."

Last edited by keefaz; 03-12-2005 at 03:18 PM.


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
remove a folder created 3 days ago. eduac Linux - Software 4 10-17-2005 12:15 PM
Uninstall or Remove Folder? sall Linux - General 4 08-07-2005 12:35 PM
how can i default the max folder file size when it create inside a folder antony_csf Linux - Software 1 06-17-2004 03:26 AM
remove folder from command line demmylls Linux - General 3 02-15-2004 10:52 AM
Remove Home folder from desktop? ceh383 Slackware 3 06-05-2003 01:18 PM

All times are GMT -5. The time now is 07:55 PM.

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