The ADCIRC development strategy consists of the maintenance of two separate versions at any given time: the stable version and the development version. The stable version only receives bug fixes, while the development version receives bug fixes as well as new features.
At some point, the development version will become stable. At that time, a new developement version will begin, and the major version number will be incremented, e.g., v48.xx will become the next development version as v49.00.
In the past the minor version number was changed each time there was a change in the code and the code was about to be distributed.
Now that svn is being used, the minor version number will be incremented on the stable version just prior to each successive public release. For the development code, the minor version should be updated each time a development branch is merged to back to trunk.
ADCIRC has had many individual contributors and has received code accretions over many years. A set of uniform coding standards has not been defined, and as a result, ADCIRC contains many different styles of Fortran. This section provides a new set of style guidelines for contributing code to ADCIRC.
We don't have a formal release process, but we need one. It should consist of:
These tests are often referred to as “regression tests,” i.e., a means to detect a regression in correctness or functionality due to changes in the code. A regression test suite can be build up pretty easily. There are a number of small test cases out there, so the initial set of tests should consist of those. We may also want to differentiate between tests for correctness and tests for functionality. The former is making sure you're getting the expected model results and the latter is making sure that nothing is broken (i.e., adcprep, i/o, message passing, etc).
Testing can get pretty complicated, but it would really just require a couple of small test cases and (most importantly) some sort of testing framework that automates much of it. Brett Estrade has volunteered to help with the framework part of it.
The test suite gets built up based on different purposes. One may want to exercise more options and more cases, but it is also important to test for known bugs that might have been reintroduced. In otherwords, once a bug is discovered and fixed, a test should be created specifically for that bug to make sure it doesn't appear again.
And lastly, a small test suite should be included with each distribution and a more comprehensive should be created that runs during development and before a release.
Subversion is a version control system. That is, it provides a means for many software developers to collaborate on a single software project.
Subversion stores the code in a repository on a central server. In our case, it is stored at RENCI and access control is handled by Brian Blanton. A software developer makes a contribution by checking out the latest version of code, making changes, and then committing the change back to the repository. The rest of us then update our local copy of the code from the repository in order to stay in synch with the latest version of the code.
Subversion repositories consist of a trunk, which is the mainline code, and any number of branches. A branch may be created by a developer that has a lot of changes to make over a longer period of time. This lone developer can work on a branch without affecting the mainline code. Once the changes in the branch are satisfactory, the branch can be merged back to the trunk, making the changes available to all.
Working with subversion requires greater coordination among ADCIRC developers. For example, if two developers change the same file in two different ways, the commit phase will fail. In other words, the Subversion program does not know which changes to accept. Furthermore, if one developer makes changes to trunk that prevent the code from compiling, it will be difficult for other developers to continue working if they update to the latest code. As a result, ADCIRC development with Subversion will adhere to the following policies:
Comprehensive documentation for Subversion is available: http://svnbook.red-bean.com/.
The ADCIRC code is hosted at the following Subversion repository location:
https://adcirc.renci.org/svn
To check out the code, please type
svn checkout https://adcirc.renci.org/svn/adcirc48
In the future, the code will probably be moved to a repository called “adcirc” rather than “adcirc48” etc. The existing names are the result of initial experimentation with creating repositories with different codebases, and it just happened to stick.
Here are a few examples of things that we commonly do with svn.
In order to see the changes between revisions of the repository, type (for example)
svn diff -r 15:16 owiwind.F
In order to create a tar file that contains just the ADCIRC code and excludes the .svn directories, the first step is to export the code to a new subdirectory. For example:
svn export ./trunk ./adc99_99
Would copy the local files under version control from the trunk subdir to the adc99_99 subdir, excluding the .svn files. Particular revisions of the svn repository can also be extracted, see the svn documentation for details on how to do this.
One advantage of using svn is that it is easy to go back to an older version of the code, if necessary. The first thing to do in this case is usually to look at the svn log to see what changes were made, so that you can select the right version of the repository to extract. Go to the subdirectory of the code tree that you want an older version of and issue the command
svn log
Look at the log entries, and note the revision that you'd like to extract. Let's say you want to retrieve adcirc48/trunk at revision 65 of the repository (for example). Issue the following command:
svn checkout -r 65 https://adcirc.renci.org/svn/adcirc48/trunk
To make a branch off trunk to add a new feature and call it the myfeature branch:
svn copy https://adcirc.renci.org/svn/adcirc48/trunk https://adcirc.renci.org/svn/adcirc48/branches/myfeature --message "Creating branch to add myfeature"
Then to start using the newly created branch:
svn checkout https://adcirc.renci.org/svn/adcirc48/branches/myfeature