next_group up previous


D0 Note #3480 - D0 Run II coding for Professors - Part II
Releasing your code upon the collaboration

H. Schellman and Alan Jonckheere

Version 0.4 - April 13, 2001

This is http://d0-www.fnal.gov/$\sim$schellma/runII_cvs/

version 3 has web release form version 4 has quotes problem fixed?

1. Introduction

This note assumes that you have a nice package written and ready to put into CVS.

2. Reserving a CVS package

To become official, you first need to ask Alan Jonckheere or his duly deputed appointee to get an empty cvs package set up for you.

He needs:

He will:

  1. go to the /d0dist/dist/CVSROOT directory and edit the files avail, to give you access to the directory, and loginfo, to set you up for notification. Be certain to also name another person who will deal with this when you don't want to.
  2. He will
    cvs commit avail loginfo
    to tell cvs about this.

  3. He will then do a
    /d0dist/dist/SRT_util/declarePkg.sh newcode
    to tell CVS about your package.

You are now set up with an empty package and access to it, you can now start installing your code. It will not be officially released until the next code release.

3. Cleanup

First you need to clean up your package. Editing and the Kai compiler have left some extra stuff in your directory tree which needs to be removed.

  1. setup d0cvs
  2. Go to your new package directory
  3. Make certain it obeys the standard conventions for directory names listed in D0 Run II coding for Professors - Part I.
  4. Make certain it compiles and runs properly
  5. Remove all core files in your package
  6. Remove all *$\sim$ files in your package
  7. Remove the ii_files that Kai made in your directory

There is a .cvsignore file that can tell cvs to ignore various files but it is not completely consistent.

4. Actually putting the whole package in CVS

You only need to do this once, or if you have completely rewritten the whole package. After importing the package you should do adds and commits of individual files.

Let's call your package newcode

  1. Check that you in fact did the cleanup
  2. go to the directory you have been putting packages in.

  3. Go into the top directory for the particular package you are trying to install:
    cd newcode
  4. do an ls -Ra and make certain you have newcode, src, test ... subdirectories.

    NOTE: BE CERTAIN THAT YOU ARE IN THE CORRECT DIRECTORY - YOU ARE INSTALLING A DIRECTORY TREE HERE AND ONLY EXPERTS CAN UNDO THIS.

  5. type:
    
    cvs import -m  ' initial import ' newcode yourname v00-00-00
    

    -m ' ' puts in a comment
    newcode is your package name
    yourname is the vendor id
    v00-00-00 is a release id

  6. go back up to your packages directory and carefully copy your package to a safe place, you are about to check the cvs version out of the repository and make certain it still works.
    cd ..
    mv newcode ../newcode.save
  7. check your package out of cvs as a check:
    addpkg -h newcode
    You need the -h

  8. gmake clean
    and remake your code, test and run.

You should now have your full package installed in cvs. How about some documentation?

5. Changing individual files in your package

5.1 Adding a subdirectory

Don't do this unless you know what you are doing, you can't remove it, an expert will have to. (But removing all the files in a directory effectively gets rid of it. It just isn't tidy.)

  1. mkdir newdirectory
  2. cvs add newdirectory
  3. cd newdirectory
  4. add or edit files into your new directory
  5. cvs add file.cpp // do this for each new file
  6. Go back up one level
    cd ..

    Tells cvs that your new directory and its contents exists

  7. cvs commit newdirectory

    Actually copies newdirectory and its contents into the repository.

5.2 Adding/changing a file

  1. edit the file
  2. check that the code compiles and runs!
  3. If new,
    cvs add filename
  4. To actually copy it into the repository,
    cvs commit filename

    WARNING - cvs commit defaults to recursive and will commit everything if you do not name your file. Do not try this at home!

Just as a check try

cvs -n update

to tell you what hasn't been committed yet.

Scott Snyder has also written

cvstat gives status for all files in your working directory
cvsmod gives status for modified files

6. Tagging your release

cvs rtag v00-01-00 newcode
will put a release tag on the current version of your package in the repository. The numbers are

first set - production release
second set - normal version number
third set - bug fix

7. Getting the code put into the D0 Code Releases

Use the web interface at http://www-d0.fnal.gov/software/cmgt/releaserequest.

The release notes can be a reference to a web page containing the real release notes. The contents of this message will be included in the Release notes for that release.

About this document ...

D0 Note #3480 - D0 Run II coding for Professors - Part II
Releasing your code upon the collaboration

This document was generated using the LaTeX2HTML translator Version 99.1 release (March 30, 1999)

Copyright © 1993, 1994, 1995, 1996, Nikos Drakos, Computer Based Learning Unit, University of Leeds.
Copyright © 1997, 1998, 1999, Ross Moore, Mathematics Department, Macquarie University, Sydney.

The command line arguments were:
latex2html -split 0 -show_section_numbers runII_cvs

The translation was initiated by WWW Server Account on 2001-04-13


next_group up previous
WWW Server Account
2001-04-13