07 Nov 2009 19:47 UTC 2009311+1947 UTC

Edit

Revisions

(All) Recent Changes

Edit


Notes on using Subversion at DNR

To obtain your own personal working copy of a DNR software project use svn checkout. For instance, if you were going to work on the voiceinfo software, you'd do the following to obtain a copy:

	svn checkout svn://meridian.tamucc.edu/trunk/voiceinfo

this will create a directory named "voiceinfo" in the current directory that you are in. Inside of the voiceinfo directory will be all of the files of the voiceinfo project. Now you are free to modify your local copy of these files.

Once you've made all of the changes that you want and you're ready to make your changes part of the official voiceinfo project there are a few other commands you need to be aware of.

svn status (svn st)

Once you've checkout a project and made some changes, you may want to review which files you've changed. svn status will tell you this information. If you also want to know which files in the repository have changed relative to your working copy (as when another developer has made some changes to files in the same project and checked them into subversion while you were making your changes), simply pass the -u option like so:

        svn status -u

This command and the others that follow are to be executed within the directory structure created by svn checkout. Subversion "remembers" where it checked the files from and will use that location as the source for all future operations (unless otherwise specified)

svn update (svn up)

This command will bring your local copy of the project up to date with the version in the repository. Any changes are noted with characters next to the files.

svn diff

svn commit (svn ci)

The svn commit command places your local changes in the subversion repository so that others may have access to them. If your changes were small, you'll want to provide the -m command line argument to specify a log message that will be associated with your change. For example, from the voiceinfo directory that you checkout out earlier:

	svn commit -m 'changed the modem connection timeout'

If your changes were more complex, don't specify -m on the command line and you will be placed in an editor determined by your EDITOR environment variable where you can expound at length upon the changes you've made. For example (also in the voiceinfo directory previously checkout):

	svn commit

since vi is in my EDITOR environment variable, it is started and I enter the following

	1. Added support for new whiz-bang voice cards
	2. removed spurious comments
	3. modified to use Device::SerialPort?
	4. Added copyright info

Then when I save and quit vi, this information will be written to the log and the changes will be commited to the subversion repository.

It is good practice to list your change information as above so that future maintainers can see what changes took place when.

In order to use svn commit you'll need to obtain a username/password from duff@lighthouse.tamucc.edu

svn log

Use svn log to view all of the log entries for particular files:

	svn log bin/voiceinfo

svn ls

List the files in the repository


Edit

Revisions

(All) Recent Changes