It's all about the answers!

Ask a question

What is the best way to move parts between components?


NANCY SCHIPON (1156) | asked May 22 '13, 1:27 p.m.
What is the best way to move parts between components?  

We are trying to split one of our large components into 2 smaller components, so we need to move a large number of files from one to the other.

1. We have tried copy and paste in the RTC Project Explorer.

2. We tried using import and export options.

3. Simply doing DOS mv and lscm copies from a command prompt.

It appears the file loses it's associated properties once it has been moved.  The lscm command does not work at this time and I have been advised that it may allow a move with the properties when RTC 4.0.3 is officially released soon.

One answer



permanent link
Tim Mok (6.6k38) | answered May 22 '13, 3:49 p.m.
JAZZ DEVELOPER
I don't think a move to another component is fully supported in the command line (see 233895: Perform "Moving projects to other components" from scm command line). If you're ok using the Eclipse client, you can move a folder in the component root to another component by right-clicking on it in Package Explorer and using Team > Move in Repository... to select another component. However, this is only supported on folders in the component root.

Comments
NANCY SCHIPON commented May 22 '13, 5:09 p.m.

Thank you for your response Tim.

The move will move everything from one location to another but I want to do a copy and then delete the unwanted files within the component folder in the new location. The Team selection does not have the "copy to repository" function.

After reading your comment we also tried a copy of the component folder and then we tried a copy of the source file folder but the properties did not copy over to the new location.


Tim Mok commented May 23 '13, 9:06 a.m.
JAZZ DEVELOPER

A move is essentially a copy and a delete. If you want to copy the files, you can perform the move but not deliver the change sets on the source component.

For the copy not preserving properties, you would be using something external to RTC for the copy. It's not under RTC's control so the properties can't be preserved.


NANCY SCHIPON commented May 23 '13, 2:23 p.m.

Appreciate your response but the needed result requires the properties to be maintained after a copy. 

Do you know if RTC will be including that capability in the near future?


Tim Mok commented May 23 '13, 3:09 p.m.
JAZZ DEVELOPER

I think you're asking for a copy in repository feature. There's a work item about supporting what you want but as a move operation (see 56504: Move files and folders between components and retain history). Since a move can be interpreted as a copy followed by a delete, it's possible that work item will fulfill your requirements. I don't know of any other work item that fulfills your requirements but you're welcome to create one.

It currently lists a workaround that may be of use to you for copying specific files instead of an entire folder from the component root. It's not elegant but will achieve preserving history and should also preserve your properties.

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.