File: release.sh

package info (click to toggle)
iptables 1.8.2-4
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 6,220 kB
  • sloc: ansic: 55,460; sh: 5,794; makefile: 208; yacc: 187; python: 83; lex: 54
file content (31 lines) | stat: -rw-r--r-- 804 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#! /bin/sh
#
set -e

VERSION=1.4.7
PREV_VERSION=1.4.6
TMPDIR=/tmp/ipt-release
IPTDIR="$TMPDIR/iptables-$VERSION"

PATCH="patch-iptables-$PREV_VERSION-$VERSION.bz2";
TARBALL="iptables-$VERSION.tar.bz2";
CHANGELOG="changes-iptables-$PREV_VERSION-$VERSION.txt";

mkdir -p "$TMPDIR"
git shortlog "v$PREV_VERSION..v$VERSION" > "$TMPDIR/$CHANGELOG"
git diff "v$PREV_VERSION..v$VERSION" | bzip2 > "$TMPDIR/$PATCH"
git archive --prefix="iptables-$VERSION/" "v$VERSION" | tar -xC "$TMPDIR/"

cd "$IPTDIR" && {
	sh autogen.sh
	cd ..
}

tar -cjf "$TARBALL" "iptables-$VERSION";
gpg -u "Netfilter Core Team" -sb "$TARBALL";
md5sum "$TARBALL" >"$TARBALL.md5sum";
sha1sum "$TARBALL" >"$TARBALL.sha1sum";

gpg -u "Netfilter Core Team" -sb "$PATCH";
md5sum "$PATCH" >"$PATCH.md5sum";
sha1sum "$PATCH" >"$PATCH.sha1sum";