#!/bin/sh
# Copyright 2008 Frank Lichtenheld <djpig@debian.org>, if at all copyrightable
# Copyright 2009 Russ Allbery <rra@debian.org>

# Helper script for updating lintian.debian.org to the latest lintian release
# Call with the release number as only argument, e.g.
#
#   $ cd /org/lintian.debian.org && ./root/reporting/checkout-release 1.25.0

set -e

if [ $# -ne 1 ]; then
    echo "Usage: checkout-release <version-number>"
    exit 2
fi
release=$1

set -x

cd root
git fetch
git merge "$release"
perl -i -pe "s/(LINTIAN_VERSION = )\S+/$1\"$release\";/" root/frontend/lintian
debian/rules build

# Local Variables:
# indent-tabs-mode: nil
# End:
# vim: syntax=sh sw=4 sts=4 sr et
