clearcaseancestorversion-tree

How do I check out from an ancestor that is not the latest ancestor in ClearCase?


Background

I have a version tree that looks like this for a directory element:

[myView] --> A  --> B --> C

It is currently looking at Version B of the directory. I want to make changes from the point of view of B. However, when I run a ct co, it will automatically do this:

[myView] --> A --> B --> C --> Checkedout

Instead of what I want below:

[myView] --> A --> B --> C
                   |
               Checkedout

Question

How can I checkout directly from an intermediate ancestor in Clearcase?


Solution

  • The cleartool checkout page has this example:

    Check out an old version of the file hello.h, using an extended path name to indicate the version. (Before you check in your revised version, you must perform a merge.)

    cleartool checkout –c "attempt fix of old bug" -version hello.h@@\main\1
    Checked out "hello.h" from version "\main\1". 
    

    So using an extended pathname (that I used here), you can checkout any version, but the checking will create a new version after C, by merging it with C.

    This is best done in a dynamic view, where all pathnames are available.