You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
scripts/update.sh

23 lines
457 B
Bash

6 years ago
#!/bin/bash
set -e -u;
if [ $# -eq 1 ]; then
cd "$1";
fi
PREFIX=release;
CONF_SCRIPT="configure.sh";
6 years ago
git pull --tags > /dev/null;
6 years ago
TAG=$(git tag --list | grep "^$PREFIX-" | sort -r | head -n 1);
if git verify-tag --raw "$TAG" 2>&1 | grep "TRUST_ULTIMATE" > /dev/null; then
git checkout "$TAG" > /dev/null;
if [ -f "$CONF_SCRIPT" ]; then
./$CONF_SCRIPT;
fi
6 years ago
else
echo "Invalid or missing signature for $TAG" >&2;
6 years ago
exit 1;
fi