From 37552c184b9509e12393532ad6cc1c7823c32255 Mon Sep 17 00:00:00 2001 From: Adriaan de Groot Date: Wed, 27 Jun 2018 12:50:20 -0400 Subject: [PATCH] ci: add a release script This is the start of a release script. The idea is to automate a whole bunch of the steps documented in ci/RELEASE.md, so that a release becomes more straightforward. Assumptions abound: basically this is going to work on my workstation, and not on any other. --- ci/RELEASE.sh | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 ci/RELEASE.sh diff --git a/ci/RELEASE.sh b/ci/RELEASE.sh new file mode 100644 index 000000000..51ca42d4f --- /dev/null +++ b/ci/RELEASE.sh @@ -0,0 +1,23 @@ +#! /bin/sh +# +# Release script for Calamares +# +# This attempts to perform the different steps of the RELEASE.md +# document automatically. It's not tested on other machines or +# setups other than [ade]'s development VM. +# +# Assumes that the version in CMakeLists.txt has been bumped, +# and that a release of that version is desired. + +test -d .git || { echo "Not at top-level." ; exit 1 ; } +test -d src/modules || { echo "No src/modules." ; exit 1 ; } + +which cmake > /dev/null 2>&1 || { echo "No cmake(1) available." ; exit 1 ; } + +rm -rf build +mkdir build || { echo "Could not create build directory." ; exit 1 ; } +( cd build && cmake .. && make -j4 ) || { echo "Could not perform test-build." ; exit 1 ; } +( cd build && make test ) || { echo "Tests failed." ; exit 1 ; } + + +