It's all about the answers!

Ask a question

Duplicate an existing stream with new name but it should be unique using rtc lscm command


Pallavi Deore (38135) | asked Apr 08 '20, 9:02 a.m.

 Hello Everyone,


I am using RTC 606.

I am trying to duplicate an TQC_Major_Stream with new name CR_test_1111 using lscm ccommand.
I used below lscm command

lscm create stream "CR_test_1111" --duplicate  "TQC_Major_Stream" -r https://localhost:9443/ccm -u pallavi -P pallavi

But if I executed same command again new stream with same stream name CR_test_1111 created.
So how to restrict creating stream with same name again using lscm duplicate command and also how we can restrict to duplicate stream in particular project area.

Thanks in advance
Pallavi Deore
 

Accepted answer


permanent link
Shashikant Padur (4.2k27) | answered Apr 08 '20, 11:43 p.m.
JAZZ DEVELOPER
I don't believe there is a way to restrict creation of same stream name.
You could probably write a custom precondition under "Save Stream" to achieve this behavior.
Pallavi Deore selected this answer as the correct answer

Comments
Pallavi Deore commented Apr 09 '20, 3:50 a.m.

 Hi Shashikant,


Is it possible to restrict duplicate command for particular project area.
And How to access UUID of Stream using Stream name. so that I can resolve the issue of ambiguity which comes when stream more than one having same name.

Thanks in advanced

Pallavi Deore 


Shashikant Padur commented Apr 09 '20, 4:27 a.m. | edited Apr 09 '20, 4:27 a.m.
JAZZ DEVELOPER
You can restrict creation of streams in a project area based on role. This will apply to both creating a stream as well as duplicating a stream.

Use the -u/--show--uuid option on any command to list the UUID's of the items in the output.
For example: lscm -u y list streams -r repo_url
or in your example: lscm -u y create stream "CR_test_1111" --duplicate  "TQC_Major_Stream" -r https://localhost:9443/ccm -u pallavi -P pallavi

Pallavi Deore commented Apr 09 '20, 7:57 a.m.

Hi Shashikant,


Can you please elaborate project area based on role while duplicating the stream.

 

One other answer



permanent link
Ralph Schoon (63.1k33645) | answered Apr 09 '20, 9:08 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
You can easily look at the roles in your project area and search for Stream to see the options you have in the permissions.

The name of the duplicated stream should be changeable. E.g. look here: https://www.ibm.com/support/knowledgecenter/SSYMRC_6.0.6.1/com.ibm.team.scm.doc/topics/set_attributes.html

Comments
Pallavi Deore commented Apr 09 '20, 9:28 a.m.

Hi Shashikant,


you have mentioned in below link 

that stream visibility and owned by can be changed using lscm commands.
How we can do it because I have checked in below link
that we can changed attribute value for only workspace,baseline,snapshot and components
But I am not getting any option to change attributes like owned by and visibility of streams using lscm commands
.

Thanks in advanced 

Pallavi Deore 


Shashikant Padur commented Apr 09 '20, 11:44 p.m.
JAZZ DEVELOPER
 -w/--workspace option applies to both workspace and stream.
Similarly there is a --ownedby option to set the owner.

Your answer


Register or 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.