** CWS tooling quick howto

From Jens-Heiner.Rechtien@sun.com Fri Jul  9 12:46:16 2004

Hi,

we are ready to go live with the CWS tooling. The stuff probably still
has some rough edges here and there, it's essentially an adaption (done
by Vladimir and me) of the in-house tools we use for some time now here
in Hamburg. Sorry Volker, I haven't been able to add your patches yet,
so for the time being this is still Unix only.

The following is just a short description of the tooling, the real
documentation is here:
http://tools.openoffice.org/dev_docs/ooo-cws-tools-doc.sxw

This tooling is for committers only, most of it (with the possible
exception of 'cwsquery' and 'cwsanalyze') doesn't make sense for the
general public.

The Prerequisites:
=================

1) The following perl modules need to be installed:
XML::Parser   -> expat based parser for the new XML based build lists
Config::Tiny  -> parsing .cwsrc configuration files
Crypt::SSLeay -> for SSL encrypted SOAP connections
SOAP::Lite    -> access the SOAP based CWS web service

2) A valid OOo CVS account. The CWS tooling connects via HTTPS to the
OOo CWS web service. As credentials is the OOo account name and the CVS
style scrambled OOo password presented. The web service then uses the
credentials to verify the legitimacy of the user with the help of the
OOo CVS server.

3) A configuration file called $HOME/.cwsrc. I've attached an example.
Enter you VCSID, scrambled CVS password, the CVS tunnel etc.

4) Check out solenv/bin and solenv/bin/modules toplevel. You'll get a
      bunch of perl scripts. The tools are:
     a) cwsquery      query misc. stuff from the CWS database
     b) cwscreate     create a CWS
     c) cwsadd        add modules to the CWS
     d) cwsaddtask    add tasks to the CWS
     e) cwsresync     resync a CWS to a new milestone
     f) cwsanalyze    analyze a CWS, compare it to the current master


How it works:
=============

1) Check out the Openoffice alias, configure, source the script.

2) To check the connection please do something like this

      $ cwsquery -m SRC680 latest

      This command should print the latest released milestone for SRC680

3) Create a CWS:

      $ cwscreate SRC680 m44 mycws01

      This creates a CWS based on SRC680 m44 called 'mycws01' (no
      underscores and other funny characters please ...)

      ATTENTION: This updates your workspace to the mentioned milestone, so
      make a copy if you have modified files in there.

4) set the CWS_WORK_STAMP environment variable

      $ setenv CWS_WORK_STAMP mycws01

5) add some modules

      $ cwsadd tools sal

6) Add some tasks to the CWS

      $ cwsaddtask i4711 i123456

7) Modify files on your CWS ...

8) Analyze your CWS in a scratch directory.

      $ cd /tmp
      $ cwsanalyze all

      This will tell you how many conflict you'll have with the current
      HEAD of the master. You can try this with every CWS, even with old
      ones which have long been integrated

9) Resync to a newer milestone. This is a 5 step operation (the
      fifth step is optional)

      $ cd /tmp
      $ cwsresync -m m45 all
      $ .. resolve your conflicts
      $ cwsresync -c all
      $ cwsresync -l m45
      $ cwsresync -r

      The -m step merges your files and protcolls all conflicts etc.
      The -c step commits the merges to the CVS. Do it always with
      cwsresync -c, never by hand!!
      The -l step updates your workspace and updates the milestone info
      of the CWS in the database
      The optional -r step removes solver and module output tree from your
      workspace. New milestones are almost always incompatible.

Caveats
=======

- does not yet work on Windows, but will RSN.
- still has some rough edges (spellling mistakes etc), probably a bug or
     two :-)

Heiner

-- 
Jens-Heiner Rechtien
rechtien@sun.com



--------------010205020207000104050109
Content-Type: text/plain; name=".cwsrc"
Content-Disposition: inline; filename=".cwsrc"
Content-Transfer-Encoding: 8bit

[CWS_CONFIG]
# Network proxy. Comment in if you need to access the net via a proxy.
# Example: PROXY=http://myproxy.company.com:8080
# PROXY=

# CWS Database server (SOAP). It's possible specify to several backup server,
# currently there are none.
CWS_DB_SERVER_1=https://eis.services.openoffice.org/soap/servlet/rpcrouter

# Your CVS login (for authentication with the CWS database).
CVS_ID=

# Your scrambled CVS password (for authentication with the CWS database).
# Take this one from .cvspass (should be last field on the line and look
# like "Aac`l;kde" or something like that)
CVS_PASSWORD=

# OOo CVS tunnel
# Example: CVS_SERVER_ROOT=pserver:cvs_id@mytunnel.mydomain.de:/cvs
CVS_SERVER_ROOT=

# Local OOo CVSUP mirror (optional)
# Example: CVS_MIRROR=:pserver:cvs_id@mycvsup.mydomain.de:/cvs
#CVS_MIRROR_ROOT=

# Path to the cvs binary (optional)
# Example: CVS_BINARY=/usr/bin/cvs
#CVS_BINARY=
