Release Procedures
==================

This is the release policy that was followed for the 0.8 SchoolTool and
SchoolBell releases.

Minor Release
=============

For bugfixes for a released version which are not Debian-specific.

1.  Receive gpg signed mails from the major contributors specifying a
    subversion revision number to release. Make sure everything is
    co-ordinated.

2.  Set version in 0.8.x branches.

    a.  Make sure the SERVER_VERSION in src/schooltool/http.py is updated.

    b.  Update the version number in setup.py and import-sampleschool.py.

    c.  Add a new Changelog entry in debian/changelog.

    d.  Check that the database is compatible with the previous version,
        if not, update db_version in debian/school{bell,tool}.{pre,post}inst.

3.  Check release notes in RELEASE.

4.  Tag new SchoolTool version.

    svn cp svn+ssh://source.schooltool.org/svn/schooltool/branches/schooltool-0.8.x \
        svn+ssh://source.schooltool.org/svn/schooltool/tags/schooltool-0.8.1

4.  Goto step 5 of `Procedure for a 0.x Release`_ using the new tags.

New Debian Revision
===================

Create a new Debian Revision for Debian-specific bugfixes.

1.  Make sure the necessary changes are in the schooltool-0.8.x branch.  Merge
    them from the trunk if necessary.

2.  Check debian/changelog.

3.  Tag new SchoolTool package revision.

    svn cp svn+ssh://source.schooltool.org/svn/schooltool/branches/schooltool-0.8.x \
        svn+ssh://source.schooltool.org/svn/schooltool/tags/schooltool-0.8-2

4.  Steps 5, 8, 9 of `Procedure for a 0.x Release`_ using the new tags.

Procedure for a 0.x Release
===========================

This is the release procedure used for release 0.8.

1.  Make sure that a mail has been received from at least one member of each
    team (POV and Etria) stating that the tree is in a reasonable release
    condition.

2.  Set version.

    a.  Make sure the SERVER_VERSION in src/schooltool/http.py is updated.

    b.  Update the version number in setup.py.

    c.  Write a new changelog entry in debian/changelog.

    d.  Make sure that db_version in debian pre/post installation scripts is
        correct and is the same.

3.  Check release notes in RELEASE.

4.  Branch and tag SchoolTool trunk.

    svn cp svn+ssh://source.schooltool.org/svn/schooltool/trunk/schooltool \
        svn+ssh://source.schooltool.org/svn/schooltool/branches/schooltool-0.8.x

    svn cp svn+ssh://source.schooltool.org/svn/schooltool/branches/schooltool-0.8.x \
        svn+ssh://source.schooltool.org/svn/schooltool/tags/schooltool-0.8

    Note: If changes to a debian package or a bugfix release are needed, they
    can be worked on in branches/schooltool-0.8.x and then tagged as
    schooltool-0.8-2 or 0.8.1-1. Depending on weather the changes were debian
    specific or not. See `Minor Release`_ and `New Debian Revision`_

    If there are any problems on any step, you can delete the branches by
    executing the following commands:
        svn rm svn+ssh://source.schooltool.org/svn/schooltool/branches/schooltool-0.8.x
        svn rm svn+ssh://source.schooltool.org/svn/schooltool/tags/schooltool-0.8

5.  Export the tag:

    svn export svn+ssh://source.schooltool.org/svn/schooltool/tags/schooltool-0.8

6.  Create tarballs from releases.

    a.  Make tarballs.
            cd schooltool-0.8
            make schooltooltar
            cd ..
            mv schooltool-0.8 schoolbell-0.8
            cd schoolbell-0.8
            make schoolbelltar
            cd ..

    b.  Make md5sum file of tarballs.
        md5sum school{tool,bell}-0.8.tar.gz > md5sum-release-0.8

    c.  Sign the md5sum with your gpg private key.

        gpg --clearsign md5sum-release-0.8
        mv md5sum-release-0.8.asc md5sum-release-0.8

    Note: always leave out the debian revision from the tarball.

7.  Go into the export and make sure that they are OK:

     cd schoolbell-0.8
     make test ftest

    Run the server and see that it works:

     ./generate-sampleschool.py
     ./schooltool-server.py
     ./schoolbell-server.py

    In a new window:

     ./import-sampleschool.py
     ./wxschooltool.py

8.  Build the Debian packages.

    a.  Copy debconf translations to debian/po

    b.  Build and sign the packages using a pbuilder chroot.
        (remeber to use --basetgz option)

    c.  Check the packages by installing/de-installing them in a clean
        sarge chroot.

    d.  Run the funtional tests against the server installed in the chroot.

        - Purge the server in the chroot,
        - Pre-seed the chroot with testserver ports.
        - Install the server.
        - Stop the server.
        - Change storage type to <mappingstorage/>
        - Add 'event-logging on' and 'test-mode on' to the server config.
        - Copy testserver_app.log to chroot/var/log/schooltool/app.log
        - Start the server.
        - Run the functional tests - 'python $sourcedir/test.py -f'

    e.  Run lintian on the .changes file. Make sure there are no warnings
        or errors.

    f.  Manually check .diff.tar.gz and .changes

    g.  Upload packages to debian unstable.

9. Write a release page for the web.  Take screenshots.

10. Upload the page, the screenshots, and the archives.

    These go in http://schooltool.org/releases/xxx

    Update the releases overview page.

11. Write an announcement to the mailing list - include release notes.

12. Write a news item for the news box on the website.

13. Maybe write a new front page headline and short announcement.

14. Send announcement, update news and web pages.

15. Send short announcement to interested outside parties:

    - Debian Edu (debian-edu@lists.debian.org)
    - SchoolForge (schoolforge-discuss@schoolforge.net)
