Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Recursively deleting a specified directory

Posted on 2002-04-30
5
240 Views
Last Modified: 2012-05-04
I have a big tree directory structure, each directory having a cvs directory inside it (except for the cvs directory itself).  I want to recursively delete just the CVS directories but leave all the others intact.  I know that I will need to use something like grep, find, rm, -R, but I can't seem to get it right.  Any ideas?  Thanks!!!!!

0
Comment
Question by:alpine
5 Comments
 

Accepted Solution

by:
rmkandan earned 100 total points
ID: 6980539
Hi alpine,

Try using the following command to delete files

find . -name "/cvs/*.*" -print | xarg rm -r | more

bye
Mani.r.
0
 

Author Comment

by:alpine
ID: 6981278
Thank you!  Not exactly correct but your help definitely brought me to the solution:

find . -name CVS -print | xargs rm -r | more

Thank you again.  You saved me a lot of time!!!!
0
 

Author Comment

by:alpine
ID: 6981282
Thank you!  Not exactly correct but your help definitely brought me to the solution:

find . -name CVS -print | xargs rm -r | more

Thank you again.  You saved me a lot of time!!!!
0
 
LVL 20

Expert Comment

by:tfewster
ID: 7621404
No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in the Cleanup topic area that this question is:
- Answered by rmkandan

Please leave any comments here before 13/1/2003

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER !

tfewster (I don't work here, I'm just an Expert :-)
0
 

Expert Comment

by:SpideyMod
ID: 7805286
per recommendation

SpideyMod
Community Support Moderator @Experts Exchange
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Can I delete authorized_keys in FreeBSD 1 99
cron job says it ran, no results 25 120
Linux: disable vim auto-comment 7 136
centos commands 6 67
Let's say you need to move the data of a file system from one partition to another. This generally involves dismounting the file system, backing it up to tapes, and restoring it to a new partition. You may also copy the file system from one place to…
I promised to write further about my project, and here I am.  First, I needed to setup the Primary Server.  You can read how in this article: Setup FreeBSD Server with full HDD encryption (http://www.experts-exchange.com/OS/Unix/BSD/FreeBSD/A_3660-S…
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question