Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to exclude files by name in a ClearCase find command?

Using the ClearCase find command, how do I find all files in a directory that do not have the name pom.xml?

I'd like to pass other selection options to the ClearCase find command so I'd prefer not to execute another command.

I am using a RedHat linux version of ClearCase. I have tried "cleartool find ! -name pom.xml -print" and that does not work.

PS: I do not use ClearCase by choice, it's mandated on my project. This is one of the reasons I hate it. I've read the man pages several times and see no clear way to do this that works!

like image 286
John in MD Avatar asked Oct 20 '08 14:10

John in MD


People also ask

How do I exclude a specific file in Linux?

Exclude Files and Directories from a List. When you need to exclude a large number of different files and directories, you can use the rsync --exclude-from flag. To do so, create a text file with the name of the files and directories you want to exclude. Then, pass the name of the file to the --exlude-from option.

How do you add a file to ClearCase?

In Rational® ClearCase® Explorer, access the view you use for your development task. Navigate to the parent directory to which you want to add the files or directories. If the files or directories are not present, drag them to the parent directory. Select the files and directories you want to add to source control.

How do I find my branch in ClearCase?

Branch, version, and label information for resources under ClearCase source control is available through the ClearTeam Navigator View. and ClearCase properties view. You can also use the ClearCase Version Tree view to find branch, version, and label information for ClearCase resources.


2 Answers

ClearCase wildcards doesn't have inversion (AFAIR) but you can use grep for this -

cleartool ls -short -nxname | grep -v pom.xml
like image 60
Dmitry Khalatov Avatar answered Nov 01 '22 11:11

Dmitry Khalatov


There is another solution which might work for you. Try

ccapply task

like image 38
Pulak Agrawal Avatar answered Nov 01 '22 10:11

Pulak Agrawal