Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

How to change RTC snapshot name at all places (including in the pending changes view snapshot)

My requirement is, I want to maintain a RTC stream snapshot of a build passed code all the time. So that any time a developer wants to accept the changes, he can just accept the changes based on that snapshot.

I am following this approach, when a build start, I crate a snapshot as “Build_in_progress” and once the build is successful, I want to rename the same to “Good_code”.

I used the below command to rename the snapshot. It changes the snapshot name, but in pending changes, I can still see the old snapshot name “Build_in_progress” and when I search for the snapshot in stream I see the new name “Good_code”.

Is there any way, I can have the updated name in pending changes. So that developer will know what code is verified and can be accepted for their work.

0 votes


Accepted answer

Permanent link
There is no command shown that you use.

A snapshot is am object and the object carries the name of the snapshot. If you change it it is changed anywhere.

In the pending changes view, what the user can see is the baselines on the components. The user can not see the snapshot there for all I know. This explains what you see, too. The snapshot is created. Since a snapshot refers to baselines on components, baselines are created if needed for the snapshot. You see these baselines in the pending changes view. The names of the baselines created are derived from the snapshot. Renaming the snapshot does not rename the baselines.

There is no accept operation based on snapshots. You can only accept baselines on individual components.
Tushar Mehta selected this answer as the correct answer

0 votes

Comments

I am using scm following command to rename a snapshot.
scm set attribute -s <<snapshot-name>> --name <<new snapshot name>> -r -u -P

If I understand it correct, a snapshot also creates a baselines on component. And probably with the same name as snapshot name. Is there a way, I can rename that baseline ?

I tried command as
scm set attribute -b <<snapshot-name>> --name <<new snapshot name>> -r -u -P
But that give as baseline not found.

See https://jazz.net/help-dev/clm/index.jsp?re=1&topic=/com.ibm.team.scm.doc/topics/set_attributes.html&scope=null

I would really suggest you look into the documentation. You have to provide the component name - just read the help.

Thanks for the pointer. I renamed the snapshot using the alias and that worked.  I am not sure, why the name was not working there.


One other answer

Permanent link
It sounds like you could take advantage of the "Post-build Deliver" feature.
-Create a Build Definition with the "Post-build Deliver" option enabled
-Crete and pick a target "green stream" where you want developers to accept from, and where you want the build to 'push' it's changes to when complete.
-Set the "trigger policy" to "Deliver if build has no errors or warnings".

This way developers are only accepting from the 'blessed/green builds'.

See the following article for additional details: https://jazz.net/library/article/649

1 vote

Comments

Thanks a lot this is going to help in my another requirement of code promotion to green stream.

Your answer

Register or log in to post your answer.

Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details
× 12,019
× 1,202
× 74

Question asked: Jul 08 '16, 1:15 a.m.

Question was seen: 7,396 times

Last updated: Jul 12 '16, 12:57 a.m.

Confirmation Cancel Confirm