Mercurial for TeamWare users

Since OpenSolaris have choosen Mercurial for Source Code Management, abandoning TeamWare, I thought I'd write a quick transition guide to help people out.

Note: TeamWare talks about workspaces while Mercurial talks about repositories.

TeamWare/SCCS commandMercurial commandComments
bringover -p /ws/onnv-clone -w ~/ws/onnv .hg clone /ws/onnv-clone onnvIf you leave out the last argument you get a repository with the same name as the parent repository
sccs edit file.cn/aYou don't have to go through this step when using Mercurial, just start editing the file
sccs prs -e file.chg log file.cShow all changes for file.c
sccs get -pm file.chg annotate -n file.cPrint file.c with the revision of each line
sccs printhg status
sccs diffshg diffMercurial shows diffs in unified diff format
sccs delget file.cn/aThis step is done when you issue hg commit (see below)
sccs unedit file.chg revert file.c
bringoverhg pull && hg updateI.e sync with parent, can be done in one step using hg pull --update
resolve -w ~/ws/onnvn/aResolving conflicts is done as part of the hg update command
workspace parenthg pathsDisplays the parent repository
workspace parent -p /ws/onnv-gaten/aIf you want to putback to a different parent you specify it when you push the changes, e.g. hg push /ws/onnv-gate
putback -n .hg status
putback < comments.txthg commit -l comments.txt && hg pushIt is the hg push that pushes the changes to the parent

I will try to add more hints for TeamWare users once we have a Mercurial repository of OpenSolaris.

[Technorati Tags: ]

Comments:

Neat, thanks! Would be interesting to add another column for the equivalent "wx" commands - with commands like "wx create" being equivalent to "hg add", etc.

Posted by Venky on September 05, 2006 at 11:51 PM PDT #

feel free to experiment (both pulling and pushing) to: /net/tonic-gate.sfbay/gates/onnv-clone it's a sandbox of ON that is reset every Monday.

Posted by stevel on September 06, 2006 at 12:34 AM PDT #

workspace parent -p <workspace path> is for changing the default parent of a workspace. Is there a way to do that in Mercurial?

Posted by Will Fiveash on September 06, 2006 at 04:09 AM PDT #

Nice stuff, very handy.

Posted by Edward Wang on September 06, 2006 at 06:06 PM PDT #

Post a Comment:
Comments are closed for this entry.
About

martin

Search

Archives
« April 2014
SunMonTueWedThuFriSat
  
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
   
       
Today