gamemode/scripts/mkrelease.sh
Stephan Lachnit 082b1c6619 mkrelease.sh: get version via git
Signed-off-by: Stephan Lachnit <stephanlachnit@protonmail.com>
2020-05-26 12:32:19 +01:00

21 lines
742 B
Bash
Executable File

#!/bin/bash
set -e
# Simple script to construct a redistributable and complete tarball of the
# gamemode tree, including the subprojects, so that it can be trivially
# packaged by distributions banning networking during build.
meson subprojects download
meson subprojects update
NAME="gamemode"
VERSION=$(git describe --tags --dirty)
./scripts/git-archive-all.sh --format tar --prefix ${NAME}-${VERSION}/ --verbose -t HEAD ${NAME}-${VERSION}.tar
xz -9 "${NAME}-${VERSION}.tar"
# Automatically sign the tarball with GPG key of user running this script
gpg --armor --detach-sign "${NAME}-${VERSION}.tar.xz"
gpg --verify "${NAME}-${VERSION}.tar.xz.asc"
sha256sum "${NAME}-${VERSION}.tar.xz" "${NAME}-${VERSION}.tar.xz.asc" > sha256sums.txt