how to get file revision from scm command line
How to get the latest revision number for any file present in the RTC SCM using the command line utilities under scmtools.
I have tried scm history. It gives details of previous checkins with an identifier as first column. E.g. Output of scm history (1031) $ USER1 "updating file" (1032) $ USER2 "First checkin to RTC " Here 1031 is the latest check in. Few questions related to above output - Are 1031, 1032 file revision numbers? If so do we have decreasing revision numbers? Is there any way to get only the latest revision number?' Thanks, Neeraj |
8 answers
How to get the latest revision number for any file present in the RTC SCM using the command line utilities under scmtools. Jazz is change set based. It uses baselines and snapshots to identify specific revisions. Few questions related to above output - No. They are aliases. See https://jazz.net/help-dev/rational-team-concert/index.jsp?topic=/com.ibm.team.scm.doc/topics/c_scm_cli.html (specifically "UUIDs and aliases") e |
Geoffrey Clemm (30.1k●3●30●35)
| answered Aug 18 '10, 4:38 p.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
Also note that in a system that supports branching, "latest" is only
semantically meaningful against some evolving context, which in RTC would be either a workspace or a stream. Cheers, Geoff On 8/18/2010 2:37 PM, echughes wrote: neerajkarandikarwrote: |
Also note that in a system that supports branching, "latest" is only neerajkarandikarwrote: Thanks Geoff and cchughes. Is there a command to get the current baseline number of a file in repository? |
Geoffrey Clemm (30.1k●3●30●35)
| answered Aug 19 '10, 9:55 p.m.
FORUM ADMINISTRATOR / FORUM MODERATOR / JAZZ DEVELOPER
A particular file state can be contained in an arbitrary number of
baselines. Are you interested in just one of them, or the list of all of them? Probably you should indicate what you want to do with that information, so we can give you more specific guidance. Cheers, Geoff On 8/19/2010 5:07 PM, neerajkarandikar wrote: gmclemmwrote: Thanks Geoff and cchughes. Is there a command to get the current baseline number of a file in repository? |
Is there a command to get the current baseline number of a file in repository? I believe that 'scm lastmod' will do what you're asking for. e |
We have shifted from SVN to RTC.
Previously along with each build we used to publish revision details for selected files in the project(E.g. Jars) using SVN INFO command. This information can be refered to at a later date to know the file version in a given build and then use it to retrieve that specific revision from SVN if required. We want to achieve similar logging in RTC. The 'scm lostMod' may not be useful, if SCM does not allow fetching previous versions of a file using that information. Thanks, Neeraj A particular file state can be contained in an arbitrary number of gmclemmwrote: Thanks Geoff and cchughes. Is there a command to get the current baseline number of a file in repository? |
neerajkarandikar wrote:
We have shifted from SVN to RTC. You just need to record the snapshot associated with that build. That is recorded in the build result, so there isn't really a need to record that separately. At some later date, you can create a new repository workspace from the snapshot, and you will have the exact same source that was used in that build. If you are only interested in certain files, then you can load only those files. |
neerajkarandikar wrote: We have shifted from SVN to RTC. You just need to record the snapshot associated with that build. That is recorded in the build result, so there isn't really a need to record that separately. At some later date, you can create a new repository workspace from the snapshot, and you will have the exact same source that was used in that build. If you are only interested in certain files, then you can load only those files. Thanks David, Snapshot should solve our problem. |
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.