Topic
  • 4 replies
  • Latest Post - ‏2014-09-16T19:31:59Z by Dave-Robinson
Ratan_k00
Ratan_k00
51 Posts

Pinned topic How to make a modified component non-modifiable in a project?

‏2013-04-05T06:15:09Z |
Hi,

I have a component and it is modified in a project. If I lock the integration stream of that project then it gets locked for all the components. If I lock the component the files in it can still be modified in any project. The component that I want to lock in a project is part of a VOB which has many components.

How to make that component non-modifibale only in that project?

Thanks!
  • Dave-Robinson
    Dave-Robinson
    116 Posts

    Re: How to make a modified component non-modifiable in a project?

    ‏2013-04-16T14:35:24Z  

    So you have tried and failed with

    >cleartool chproj -dmod src@\projects Product_2.0@\projects
    cleartool: Error: Component "src" has been modified in stream "drobin_Product_2.0", cannot make it unmodifiable.
    cleartool: Error: Unable to remove one or more of the specified components
    from the modifiable component list of project "Product_2.0@\projects".

     

    The error message tells you that what you are trying to do is not supported.

    However, it can be done if you are determined.

    >cleartool lsproj -fmt "%[mod_comps]CXp\n" Product_2.0@\projects
    component:doc@\projects, component:src@\projects

    >ucmutil lspvar -pvar SUM_PROJ_MOD_COMPS project:Product_2.0@\projects
        PVAR= SUM_PROJ_MOD_COMPS    Value= ",oid:1c2bf5bb.68294591.b812.69:a5:e8:10:42:63@vobuuid:03855389.7302451b.ba8b.a2:
    37:06:0f:8b:3d,oid:93335f74.9a8947d9.9be5.27:58:d0:bc:6a:72@vobuuid:03855389.7302451b.ba8b.a2:37:06:0f:8b:3d"

     

    >ucmutil setpvar -pvar SUM_PROJ_MOD_COMPS -value ",oid:1c2bf5bb.68294591.b812.69:a5:e8:10:42:63@vobuuid:03855389.7302451b.ba8b.a2:37:06:0f:8b:3d" project:Product_2.0@\projects

    You are about to modify internal data. Any mistake will damage the objects.
    Do you want to continue? [no] y
        Set SUM_PROJ_MOD_COMPS = ",oid:1c2bf5bb.68294591.b812.69:a5:e8:10:42:63@vobuuid:03855389.7302451b.ba8b.a2:37:06:0f:8
    b:3d"    [existed]

     

    >cleartool lsproj -fmt "%[mod_comps]CXp\n" Product_2.0@\projects
    component:doc@\projects

    You then need to regenerate the config spec of every stream and every view in the project

    cleartool chstream -generate stream-selector

    cleartool setcs -stream -tag view-tag

      and checkouts for that component are now disabled.

     Note the warning about making mistakes !!!

  • JirongHu
    JirongHu
    687 Posts

    Re: How to make a modified component non-modifiable in a project?

    ‏2013-04-30T13:42:41Z  

    As I know, you can't make a modify component to non-modify.

  • GautamShankar
    GautamShankar
    1 Post

    Re: How to make a modified component non-modifiable in a project?

    ‏2014-09-16T17:59:44Z  

    So you have tried and failed with

    >cleartool chproj -dmod src@\projects Product_2.0@\projects
    cleartool: Error: Component "src" has been modified in stream "drobin_Product_2.0", cannot make it unmodifiable.
    cleartool: Error: Unable to remove one or more of the specified components
    from the modifiable component list of project "Product_2.0@\projects".

     

    The error message tells you that what you are trying to do is not supported.

    However, it can be done if you are determined.

    >cleartool lsproj -fmt "%[mod_comps]CXp\n" Product_2.0@\projects
    component:doc@\projects, component:src@\projects

    >ucmutil lspvar -pvar SUM_PROJ_MOD_COMPS project:Product_2.0@\projects
        PVAR= SUM_PROJ_MOD_COMPS    Value= ",oid:1c2bf5bb.68294591.b812.69:a5:e8:10:42:63@vobuuid:03855389.7302451b.ba8b.a2:
    37:06:0f:8b:3d,oid:93335f74.9a8947d9.9be5.27:58:d0:bc:6a:72@vobuuid:03855389.7302451b.ba8b.a2:37:06:0f:8b:3d"

     

    >ucmutil setpvar -pvar SUM_PROJ_MOD_COMPS -value ",oid:1c2bf5bb.68294591.b812.69:a5:e8:10:42:63@vobuuid:03855389.7302451b.ba8b.a2:37:06:0f:8b:3d" project:Product_2.0@\projects

    You are about to modify internal data. Any mistake will damage the objects.
    Do you want to continue? [no] y
        Set SUM_PROJ_MOD_COMPS = ",oid:1c2bf5bb.68294591.b812.69:a5:e8:10:42:63@vobuuid:03855389.7302451b.ba8b.a2:37:06:0f:8
    b:3d"    [existed]

     

    >cleartool lsproj -fmt "%[mod_comps]CXp\n" Product_2.0@\projects
    component:doc@\projects

    You then need to regenerate the config spec of every stream and every view in the project

    cleartool chstream -generate stream-selector

    cleartool setcs -stream -tag view-tag

      and checkouts for that component are now disabled.

     Note the warning about making mistakes !!!

    Hi,

    I get an error when trying to retrieve the values. Please help me to resolve this issue.

    usbgl% cd /opt/rational/clearcase/etc/utils/

    usbgl% ./ucmutil lspvar -pvar SUM_PROJECT_MOD_COMPS project:test_infra@/vobs/globe_pvob

    SUM_PROJECT_MOD_COMPS = ??? [PVAR not found]

     

    Thanks,

    Gautam

  • Dave-Robinson
    Dave-Robinson
    116 Posts

    Re: How to make a modified component non-modifiable in a project?

    ‏2014-09-16T19:31:59Z  

    Hi,

    I get an error when trying to retrieve the values. Please help me to resolve this issue.

    usbgl% cd /opt/rational/clearcase/etc/utils/

    usbgl% ./ucmutil lspvar -pvar SUM_PROJECT_MOD_COMPS project:test_infra@/vobs/globe_pvob

    SUM_PROJECT_MOD_COMPS = ??? [PVAR not found]

     

    Thanks,

    Gautam

    The variable is called SUM_PROJ_MOD_COMPS

                  not SUM_PROJECT_MOD_COMPS