JAVA调起clearcase_ClearCase简单使用 (转)

ct ci -nc /vob/su_java/code/src

Accessional

We usually only check in the file, but forget to check in the directory. This will cause the file you created can't be stored in the VOB and can't be seen by other people.

Go to the top project folder, use below command to list all checked out files and directories int the current dir and sub dir in your view. It will help you check in all elements.

ct lsco -cview -r

7. Now, your task is ongoing. In coding and testing, you may need to merge your file to other version. below example gives the merge steps:

Usually you may also need to compare two versions

Compare this version from the previous version

Accessional

Use this command to list all versions of an element

ct lsvt hello.c

include the merge info

ct lsvt -merge hello.c

Remove a merge arrow:

Dont do actual merge, just draw a merge line

In what cases we need merge:

Integrate with the code developed by someone else.

If baseline version has been incresed, need upermage.

Merge for release.

8. If you want to remove an un-use version, use the command

Then the version 2 will be removed, but next time the version will increase from 1 to 3.

If you want to remove a file, you can use remove name command:

ct rmname hello.c

Be sure to make branch and check out the current directory before rmove it, just like the steps of make element.

If you want to rename a file, you can use

ct mv old_name new_name

If you want to create an element link, you can use

ct ln source_file file_link

(checkout current folder like above)

9. Now you may have completed the task of coding, testing, inspection, and prepare to release it. You need to check your developed version is complied with below rules:

Must make branch from the baseline version.

Must have up merged your branch if the baseline version is not the LATEST version.

All the files and directories have no checkou.

10. How to label the version

Make the label type:

ct mklbtype BLUETOOTH_00.07.00

Make label on a version:

ct mklabel BLUETOOTH_00.07.00 hello.c@@/main/branchto/2

Move a label from the old version to a new version:

ct mklabel -replace BLUETOOTH_00.07.00 hello.c@@/main/branchto/3

Remove label on a version:

ct rmlabel BLUETOOTH_00.07.00 hello.c@@/main/branchto/3

Remove the label type

ct rmtype lbtype:BLUETOOTH_00.07.00

11. How to search the reuqired version

Find all files with the version(.../ISGcq00373766/LATEST) and with no label SAMBA_AP_DSL_BLUETOOTH_00.00.07:

ct find /vob/directory -version 'version(.../ISGcq00373766/LATEST)  && !version(SAMBA_AP_DSL_BLUETOOTH_00.00.07)' -print

Find all files with the version SAMBA_AP_DSL_BLUETOOTH_00.00.07, and then search STRING in all found files:

ct find .-version 'version(SAMBA_AP_DSL_BLUETOOTH_00.00.07)' -exec 'grep STRING $CLEARCASE_PN'

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值