Jump to content

Porting build script to Plastic SCM


omri.spector

Recommended Posts

I am currently porting my release build scripts (NAnt) from CVS to Plastic. To my amazement the port is not straight-forward.

In my scripts I:

- Open a clean directory

- Connect to Server and Repository

- Get sources for a specific label on trunk

- Build

But in Plastic:

- I don't see any command allowing connect to server except "cm mkrep" - but I don't want to create a new repository!

- I don't see any way to get sources by label: "cm update" does not have a label parameter.

Furthermore - even in the GUI I don't see any easy way to locally get a specific revision of a file

What am I missing?

Thank you for any help,

Omri

Link to comment
Share on other sites

Hi Omri,

I guess it's different to CVS. Here is a possible way to do it.

One-time steps:

- To connect to the server, you need to configure your client. You can run plastic --configure and enter the details of the server and credentials if needed.

- To get the sources, you need to create a workspace, that will receive the source. From the command line:

cm mkwk workspacename workspacepath

Then, when you want to build, you need to set what to download on your workspace. For that you set the selector of the workspace. For instance, to load a label you create a file (let's say selector.txt) with this content:

repository "<your repository>" path "/" label "<your label>"

Now use the set selector command, that will automatically update the workspace:

cm sts [path to your workspace] --file=selector.txt

Cheers!

David

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...