[development] SCM discussion.

Gordon Heydon gordon at heydon.com.au
Fri Nov 25 00:18:20 UTC 2005


With all the discussion on which SCM (Source Code Management) system we
should be using.

There has always been talk of using SVN, and recently I proposed darcs
and in the last couple of days there has been bzr. These are all good
SCM's but I am wondering if we are going to not have some of the
important functionality that we currently have.

I think I am most likely in the minority of users that use nesting to
set up a site. I know that with darcs I am going to loss this ability
and I also think with bzr we would as well.

Basically this is how I set up a brand new site.

First I check out the core of drupal

$ cvs -z9 -d:pserver:anonymous:anonymous at cvs.drupal.org:/cvs/drupal
checkout -d drupal_new drupal

Using the -d option I can specify the directory to put it into. Also if
I am doing a 4.6 install I add -r DRUPAL_4_6

Once I have the base setup, edited the settings, create the database,
create user 1, etc.

Then I go to the modules directory and I start checking out the modules
that I need, with the following command to get it out of cvs.

$ cvs -d:pserver:anonymous at cvs.drupal.org:/cvs/drupal-contrib checkout
-d htmlarea contributions/modules/htmlarea

This will check out the htmlarea module and put it into my modules

I repeat this for all the modules that I need.

if this is a 4.6 install I will then go to the themes/engines and use
the same command to checkout phptemplate, and then I will usually check
out the bluemarine phptemplate theme into the themes directory like co.

$ cvs -d:pserver:anonymous at cvs.drupal.org:/cvs/drupal-contrib checkout
-d bluemarine-phptemplate -r DRUPAL_4_6 contributions/themes/bluemarine

Now once I have done all this, keeping the site up to date is extremely
simple. all I do is go to the root of the drupal install and do a.

$ cvs update -dP

which will not only update the core but also update the contributed
modules which are in a different repository. I can also do things like
upgrade between versions with a

cvs update -r DRUPAL_4_7

which will do the same.

This is a function of cvs that makes my life so much easier to maintain
sites, and keep them current. It also makes things easier when I am
doing development of my contributed modules as I do not need to copy
them back to another directory to be commited, I can commit them from my
working directory.

I know that darcs can't do this, and I am not sure about bzr. I feel
this is an underused function that really more people should know about
and should really not be lost.

Any SCM that is chosen needs to be done wisely, and make sure that it
does fit our method of working. Because of the 2 repositories we are not
what would be called normal, so we need to allow for this.



More information about the development mailing list