masqmail

diff devel/gen-dist @ 226:7b70bf4f1f42

renamed misc/ to devel/ because the contents are for developers
author meillo@marmaro.de
date Fri, 23 Jul 2010 11:46:08 +0200
parents misc/gen-dist@b212da6385a8
children
line diff
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/devel/gen-dist	Fri Jul 23 11:46:08 2010 +0200
     1.3 @@ -0,0 +1,23 @@
     1.4 +#!/bin/sh
     1.5 +#
     1.6 +# generate a tar.gz archive to distribute
     1.7 +# generate an md5sum and a detached signature of the archive
     1.8 +#
     1.9 +# requires:
    1.10 +# - mercurial (hg)
    1.11 +# - md5sum
    1.12 +# - gnupg
    1.13 +
    1.14 +if [ $# -ne 1 -o -e "$1" ] ; then
    1.15 +	echo "usage: gen-dist DEST.tar.gz" 2>&1
    1.16 +	exit 1
    1.17 +fi
    1.18 +
    1.19 +dir="${1%/*}"
    1.20 +file="${1##*/}"
    1.21 +
    1.22 +hg archive -t tgz -X .hg\* "$1"
    1.23 +
    1.24 +cd "$dir"
    1.25 +md5sum "$file" >"$file.md5sum"
    1.26 +gpg -ab "$file"