What is the proper way to use scm for automated loads from a stream?
![]()
Jeffrey Cheng (1●1●3●3)
| asked Oct 02 '13, 9:19 p.m.
edited Oct 03 '13, 12:12 p.m. by Geoffrey Clemm (30.1k●3●30●35)
I would like to do a fresh load from a stream for each of our daily/weekly builds. Do I always need to "accept" into a workspace first and then load it into the sandbox?
The following is from the documentation on the accept command:
When I run the scm accept command however, I don't see any files in the sandbox (it said "Workspace unchanged"). Is there a way to accept AND load files in 1 operation. I essentially want to do something similar to an "svn export" or "svn co" if that helps clarify what I'm asking.
|
One answer
![]()
Geoffrey Clemm (30.1k●3●30●35)
| answered Oct 03 '13, 1:11 a.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
First note that this must be documentation from a pre-4.0.4 release ... since we don't use the term "local workspace" anymore ... we use the term "sandbox". Note that the documentation says that the accepted change sets are automatically loaded *if you run it in a local workspace [i.e., sandbox]*. In other words, if you have the repository workspace loaded, then accepts into that repository workspace will automatically be loaded (because RTC always tries to keep a local workspace and its sandbox in sync).
So you first need to load the repository workspace, and then newly accepted changes will be automatically loaded. And this does require two commands ... both a "load" command and an "accept" command (unless you happen to know that the repository workspace is up-to-date WRT the stream, in which case a "load" is sufficient). Note: In RTC we use the term "load" to refer to the process of loading files from the repository workspace to the sandbox, not "check out". Comments Thanks Geoff. From an automated perspective, is there a command or some way to tell if a workspace has already been loaded? Since I do not know at the time of starting a build, my workaround right now is to do 1) Accept all changes to the workspace followed by 2) Force load.
scm accept -r jazz -t MY_WORKSPACE
scm load MY_WORKSPACE--force -r jazz
I added the force option just to make sure I have the latest code placed into the sandbox. Would you recommend this approach?
|
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.
Comments
Hi Jeffrey,
I suppose it doesn't always have to be a fresh load, but I cannot always guarantee that whatever code is in the sandbox will be the latest or has not been modified. In our current process (using a different version control system) we are accustomed to performing a fresh load upon each build.
Note: I modified the title and text of this question to use the RTC term "load" instead of the non-RTC term "checkout".