Reputation: 53
I have:
Now I want know the list of files checked-in in view.
What command should I use?
Upvotes: 1
Views: 999
Reputation: 1324397
One way would be to use cleartool ls
, and grep for /main/LATEST (or just LATEST if you don't care of the branch selected, depending on your config spec)
cleartool ls -r -view|grep LATEST
Only versioned checked-in file would be listed that way.
Using cleartool find
is also a possibility, but would list versions even for files which are checked out, which is not what you want.
See those examples to illustrate the difference.
to list element versions on a branch but exclude checkedout versions
- The first example lists all element versions including any CHECKEDOUT versions.
- The second example shows how to list all element versions, but excluding any CHECKEDOUT versions.
EXAMPLE 1:
> cleartool find . -version "brtype(bugfix)" -print
./a.c@@/main/bugfix/0
./a.c@@/main/bugfix/1
./a.c@@/main/bugfix/2
./a.c@@/main/bugfix/CHECKEDOUT
./golf.c@@/main/bugfix/0
./golf.c@@/main/bugfix/1
EXAMPLE 2
> cleartool find . -version "brtype(bugfix)" -print | grep -v CHECKEDOUT
./a.c@@/main/bugfix/0
./a.c@@/main/bugfix/1
./a.c@@/main/bugfix/2
./golf.c@@/main/bugfix/0
./golf.c@@/main/bugfix/1
Upvotes: 0