blob: 08264a0d505f766540c8f013cf24bfb7e4e0ec62 (
plain) (
blame)
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
|
#!/bin/sh
# See LICENSE file for copyright and license details.
set -e
if test ! $# = 3; then
printf 'usage: %s git-dir project version\n' "$0" >&2
exit 1
fi
die () {
printf '%s\n' "$@" >&2
exit 1
}
gitdir="$1"
tarball=".static/$2-$3.tar.gz"
infofile="rel/$2/$3.info"
sumfile="rel/$2/$3.checksums"
test -e "${tarball}" || die "${tarball} does not exist"
test -e "${infofile}" || die "${infofile} does not exist"
grep '^Tarball: ' < "${infofile}" | cut -d ' ' -f 2 | \
grep -v '^https://maandree.se/static/' |
"$(dirname -- "$0")"/util/gen-checksums "${tarball}" "${gitdir}" > "${sumfile}"
|