Search code examples
clearcase

How do I write a Rational ClearCase config spec to checkout based on a directory?


I am new to Rational and I have to add functionality to an existing program to support a new program. The applications are small and in a directory structure, they are on the same level. What I would like to do is - when I perform a CheckOut under the legacy application the files are checked out under a new branch. When I check out under the new application, the files are checked out under the standard /main branch. Here's kinda what it looks like:

  /main
        /CGI_Legacy
              /CGI_Extended
  /NewApp

It is my job to create the CGI_Extended and NewApp applications. CGI_Extended represents the new branch.

Thanks


Solution

  • Don't mix directories and branches.

    Branches are set in the config spec of a ClearCase view, which, for base ClearCase view, would look like:

    element * CHECKEDOUT
    element /MyVob/Legacy/... .../CGI_Extended/LATEST
    element /MyVob/Legacy/... /main/LATEST -mkbranch CGI_Extended
    element /NewApp/... /main/LATEST
    

    See also:

    This won't create a directory CGI_Extended, and will keep the files in their original directory, but will create an new branch CGI_Extended on each checkout.