Repository

Repository Management

The repository is where files and source code is stored and version controlled. This is referred to as SCM: Source Configuration Management. Antmod supports multiple repository systems through its repository providers. An SCM repository is used to store:

  • Modules;
    the modules are consistently tagged and branched

  • Release descriptors;
    the release descriptors are stored in the "releases" module as XML files

  • Java Libraries;
    the java libraries are stored in the "javalib" module as binary files, but can also be on a web server outside the SCM repository

  • Centralized Configuration;
    centralized properties are stored in the SCM repository, automatically overriding Antmod defaults for all developers

Configuring Repositories

Repositories can be configured in ${HOME}/.antmodrc (or in the centralized configuration inside the SCM repository) using this scheme:

  antmod.repositories.<reposname>=scm:<provider>:<provider-parameters>

Each configured repository has a name. This repository name is used in release descriptors for each module, such that it is clear in which repository the module is stored. In the following example the module called "somemodule" is stored in a CVS repository called "bigcvsrepository":

  • in "${HOME}/.antmodrc":
    antmod.repositories.bigcvsrepository=scm:cvs:pserver:user:password@host:/cvs/root

  • in "somerelease/dev.xml":
    <module name="somemodule" type="main" version="trunk" repos="bigcvsrepository"/>

The SCM URL format is fully documented in the ScmUrl API documentation.

Some SCM repository URL examples:

# scm repository url for the repository with the name "default"
#
# CVS examples:
#   scm:cvs:pserver:user:password@host:/cvs/root
#   scm:cvs:local:ignored:/cvs/root
#   scm:cvs:ext:user@host:/cvs/root
#
# Subversion examples:
#   scm:svn:http://user:password@host.example.com/path/to/svn
#   scm:svn:http://host.example.com/path/to/svn
#   scm:svn:svn://host.example.com/path/to/svn
#   scm:svn:file:///path/to/svn
#   scm:svn:file:///cygdrive/c/data/localsvn
#   scm:svn:file:///C:/data/localsvn

Refer to the Release Descriptor reference for more information on the usage of the "repos" attribute of a module.
Refer to the Configuration reference to see the standard configuration parameters for repositories.