3 # script to build a release announcement for the Monkeysphere
4 # if you're running this, you probably also want to read through
5 # the checklist in utils/preparing-release.
7 # Author: Daniel Kahn Gillmor <dkg@fifthhorseman.net>
8 # Copyright: © 2008-2010
9 # License: GPL, v3 or later
11 VERSION=`head -n1 Changelog | sed 's/.*(\([^)]*\)).*/\1/'`
12 WEBSITEDIR=../monkeysphere-docs/website
14 if [ ! -d "$WEBSITEDIR" ]; then
15 echo "you need to check out the monkeysphere-docs git repo" >&2
16 echo "as a peer of this repository to create a releasenote" >&2
21 sed "s/__VERSION__/$VERSION/g" < utils/releasenote.header
22 head -n$(( $(grep -n '^ --' Changelog | head -n1 | cut -f1 -d:) - 2 )) Changelog | tail -n+3
23 sed "s/__VERSION__/$VERSION/g" < utils/releasenote.footer
24 } > "$WEBSITEDIR/news/release-$VERSION.mdwn"
26 (cd "$WEBSITEDIR" && git add "news/release-$VERSION.mdwn" )
29 echo "checksums for the monkeysphere ${VERSION%%-*} release:"
32 md5sum "../monkeysphere_${VERSION%%-*}.orig.tar.gz"
35 sha1sum "../monkeysphere_${VERSION%%-*}.orig.tar.gz"
38 sha256sum "../monkeysphere_${VERSION%%-*}.orig.tar.gz"
43 temprelease=$(mktemp ${TMPDIR:-/tmp}/tmp.XXXXXXXXXX)
44 trap "rm -f $temprelease" EXIT
46 head -n$(( $(grep -n '^-----BEGIN PGP SIGNED MESSAGE-----$' "$WEBSITEDIR/download.mdwn" | head -n1 | cut -f1 -d:) - 1 )) "$WEBSITEDIR/download.mdwn" | \
47 sed -e 's|http://archive\.monkeysphere\.info/debian/pool/monkeysphere/m/monkeysphere/monkeysphere_[[:digit:].]\+\.orig\.tar\.gz|http://archive.monkeysphere.info/debian/pool/monkeysphere/m/monkeysphere/monkeysphere_'"${VERSION%%-*}"'.orig.tar.gz|g' >$temprelease
48 checksums | gpg --no-tty --clearsign --default-key EB8AF314 >>$temprelease
49 cat utils/download.mdwn.footer >>$temprelease
50 mv "$temprelease" "$WEBSITEDIR/download.mdwn"
54 (cd "$WEBSITEDIR" && git add "download.mdwn")
56 gpg --verify "$WEBSITEDIR/download.mdwn"
58 printf "please remember to add the new version to the bugtracker:\n https://labs.riseup.net/code/projects/settings/monkeysphere\n"