Debian

Contributing to Debian development
In line with Debian policy, .deb packaging instructions are not included in the upstream Mercurial repositories. Instead, the Debian packagers track their changes in Mercurial repositories on alioth.debian.org, where they are maintained in per-release branches.

Notes for Debian Developers
If you are a Debian Developer in the debian-ha team, you have push access to the Mercurial repositories on alioth. To set things up, please follow these steps:

Below is an example for working with the cluster-glue repository. However, the same procedure must be followed for the heartbeat and cluster-agents repositories.

Create a working directory
First, create a working directory: mkdir cluster-glue cd cluster-glue hg init

Now, edit .hg/hgrc, filling in the following information: [paths] upstream = http://hg.linux-ha.org/glue debian = ssh://your_username@alioth.debian.org//srv/hg.debian.org/hg/debian-ha/cluster-glue

Pull from upstream
You must now populate your working directory with a checkout from upstream: hg pull upstream

Fetch branches
Next, fetch the Mercurial branch for every distribution managed in the upstream repository: hg pull debian -r sid hg pull debian -r squeeze hg pull debian -r lenny

Now, your hg branches output should list a total of 4 branches, one named default (from upstream), and three more named sid, squeeze, and lenny (from alioth).

Make modifications to Debian packaging
If you need to make a change to Debian packaging for a particular Debian release, follow this pattern:

Make sure you have the latest state of Debian packaging in your working directory: hg pull debian -r sid

Update your working directory for the release your modifications apply to:

hg update -C sid

Make your modifications, issuing hg commit after each one. Be sure to include a meaningful changeset description. When you are done, you can issue the following command to get an overview of those changesets present in your local working directory, but not yet pushed to alioth:

hg outgoing debian

Finally, you can push your changes:

hg push debian -r sid

Tracking upstream
At certain points, you will want to import all changes to upstream into the Debian branches (this will typically occur after upstream releases). To do so, again, use merging. For example, if you want to create a new sid package because a release has happened upstream, proceed as follows:

Switch to the sid branch: hg update -C sid

Pull from upstream and update your working directory to a tagged release: hg pull upstream hg merge -r cluster-glue-1.0.3 hg commit -m "New upstream release 1.0.3"

Make any necessary changes to Debian packaging. Again, commit them in logical chunks, with meaningful commit messages. Then, push the changes to alioth:

hg outgoing debian -r sid hg push debian -r sid

Notes for non-DDs
If you are not a Debian Developer, you can still help with Debian packages! You will not be able to push directly into the Debian repositories, but you can still submit patches which the Debian maintainers can then incorporate into their packaging.

Below is an example for working with the cluster-glue repository. However, the same procedure should be followed for the heartbeat and cluster-agents repositories.

Create a working directory
First, create a working directory cloned from the Debian repository: hg clone http://hg.debian.org/hg/debian-ha/cluster-glue

Fetch branches
Next, fetch the Mercurial branch for the distribution where you wish to contribute (in this example, sid) hg pull -r sid

Now, your hg branches output should list a new branch, sid (from alioth).

Make modifications to Debian packaging
If you need to make a change to Debian packaging for a particular Debian release, follow this pattern:

Make sure you have the latest state of Debian packaging in your working directory: hg pull -r sid

Update your working directory for the release your modificiations apply to:

hg update -C sid

Make your modifications, issuing hg commit after each one. Be sure to include a meaningful changeset description. When you are done, you can issue the following command to get an overview of those changesets present in your local working directory, but not in the repository on alioth:

hg outgoing -r sid

Submitting your modifications for review
Finally, you can submit your changes for review on the mailing list:

hg email --outgoing -r sid --to debian-ha-maintainers@lists.alioth.debian.org

One of the Debian package maintainers will then get back to you with feedback about your patch. If you don't hear back within a couple of days, be sure to poke us about it.