2

I am moving from clearcase-lite (CC-LT) to SVN.

I need to list all the files of specific snapshot that are NOT elements so I can ignore them in my initial import to SVN.

Can you suggest on a shell or clear-case CLI to do that?

YanivN
  • 391
  • 1
  • 3
  • 9

2 Answers2

1

I also have symbolic links as elements As I wrote in how to keep includes in svn that I want to keep also in the repository.

I had to add those separately using the following command:

> cleartool ls -rec | grep "\-->"

while non elements do not keep the -->:

> ct ls Include/not_element.h
Include/not_element.h
> ct ls Include/element.h 
Include/element.h --> ../NetworkInterface/element.h
Community
  • 1
  • 1
YanivN
  • 391
  • 1
  • 3
  • 9
0

cleartool ls is the main command here, for snapshot view (as opposed to lsprivate for dynamic views)

cleartool ls -view_only -r

But that list too many elements.

See "Command to find all view private files in the current directory recursively"

For Windows:

@echo off
setlocal
for /F "usebackq delims=" %%A in (`cleartool ls  -rec ^| find /V "Rule:" ^| find /V "hijacked" ^| find /V "eclipsed" ^| find /V "-->"`) do @echo "%%A"

For Unix:

cleartool ls -rec | grep -v "Rule:" | grep -v "hijacked" | grep -v "eclipsed" | grep -v -- "-->" 

similar ideas are in:

Community
  • 1
  • 1
VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250
  • Thanks @VonC, works perfectly. I used the last command you suggested above (UNIX) with some extra exceptions of my own. – YanivN Jul 10 '14 at 09:24