Reputation: 8980
In the ClearCase Remote Client is it possible to find a list of all hijacked files in a given view?
Upvotes: 4
Views: 2525
Reputation: 47
Hijacking an element in a snapshot view involves making it writable and making a change to it. There is no lshijack or lsprivate -hijacked command to list the files. While the cleartool update operation does generate a log identifying hijacked files, the best way is to use cleartool ls command which identifies hijacked versions in much less time than an update would take. Use cleartool ls from the command line and look for the [hijacked] tag on objects.
Example output:
%> cleartool ls
archive.ppt@@\main\1 [hijacked] Rule: \main\LATEST
project.doc@@\main\1 Rule: \main\LATEST
doc_resources.ppt@@\main\2 [hijacked] Rule: \main\LATEST
To obtain a list of all hijacked files in a snapshot view, use the following command:
On UNIX® and Linux® you can run the following command from a snapshot view:
cleartool ls -recurse | grep "hijacked"
On Microsoft® Windows® you can run the following command from a snapshot view:
cleartool ls -recurse | findstr "hijacked"
This command will perform a recursive "cleartool ls"
and then use "grep"
or
"findstr"
command respectively to filter any lines that have the [hijacked] line associated with them.
Note: GREP is a native UNIX command; however, it can be run on Windows if the utility is installed. The grep tool comes with applications like GNU, Free Software Foundation or Cygwin
Upvotes: -1
Reputation: 1403
Right-click on your view and select Show Pending Changes
. All of your hijacked files will be displayed at the top of the list under the heading Hijacked Resources
.
Upvotes: 3
Reputation: 8980
It's also possible through the UI, albeit indirectly.
If you run "Refresh > Update from Repository..."
off the context menu, the UI will present you with a list of files it did not update upon completion. This will include all hijacked files.
If you're looking to check out the hijacked files, you can select them all and check them out from that display.
Upvotes: 1
Reputation: 1324407
Detecting hijacked files in a web or CCRC view can be tricky, depending on the state of the view itself.
For instance, the .COPYAREA.DB
file, if missing or corrupt, means that all or some of the loaded files will appear to be hijacked. (see "About the .copyarea.dat
and .copyarea.db
files")
Other bugs (swg1PK64597, swg21433085
) can affect the list of hijacked files as well, depending on your ClearCase version and your OS.
Another way to list hijacked files it to look for "skipped object" after an rcleartool update
:
rcleartool update -noverwrite
(with -nov/erwrite
leaving all hijacked files in the view with their current modifications)
Upvotes: 0
Reputation: 1436
In a snapshot view, it is possible to do so using 'cleartool ls -recurse | grep hijacked' (Unix/Linux) or 'cleartool ls -recurse | findstr "hijacked"' (for Windows)
See the link Identifying hijacked files in a snapshot view
In a Web view or CCRC view, I would think that you should be able to do the same if you have installed rcleartool.
The command "rcleartool ls -recurse | grep hijacked" should work the same way.
Note: Depending on the version of CC on your server, rcleartool you need to use is either a separate zip or either included in the CCRC rich client. It is not included by default in the CCRC plugin for eclipse.
Upvotes: 0