#!/bin/bash # # Copyright (C) 2017 Wolfgang Wiedmeyer # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation, either version 3 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program. If not, see . # RELEASE="" if [ -z "${RELEASE}" ] ; then echo "You need to define the RELEASE variable in the releasevars.sh script." echo "This needs to reflect the Replicant version you are releasing." echo echo "For example, if you are releasing Replicant 6.0 0004 RC2, you can use:" echo " RELEASE=\"6.0-0004-rc2\"" echo echo "Or if you just want to release a build from the replicant-6.0 branch:" echo " RELEASE=\"6.0\"" exit 1 fi # The files are in out/dist/${device}/ RELEASE_IMAGES="\ recovery-i9100.img \ recovery-n7000.img \ recovery-maguro.img \ recovery-espressowifi.img \ recovery-espresso3g.img \ recovery-i9300.img \ recovery-n7100.img \ recovery-i9305.img \ recovery-n5100.img \ recovery-n5110.img \ replicant-${RELEASE}-i9100.zip \ replicant-${RELEASE}-n7000.zip \ replicant-${RELEASE}-maguro.zip \ replicant-${RELEASE}-espressowifi.zip \ replicant-${RELEASE}-espresso3g.zip \ replicant-${RELEASE}-i9300.zip \ replicant-${RELEASE}-n7100.zip \ replicant-${RELEASE}-i9305.zip \ replicant-${RELEASE}-n5100.zip \ replicant-${RELEASE}-n5110.zip \ " RELEASE_DEVICES="\ i9100 \ n7000 \ maguro \ espressowifi \ espresso3g \ i9300 \ n7100 \ i9305 \ n5100 \ n5110 \ " RELEASE_KEY="" if [ -z "${RELEASE_KEY}" ] ; then echo "You need to define the RELEASE_KEY variable in the releasevars.sh script." echo "This variable contains the gpg key that will sign the images you are releasing." echo echo "For example:" echo " RELEASE_KEY=\"FB31DBA3AB8DB76A4157329F7651568F80374459\"" exit 1 fi REPO="repo" COLOR=1 METADATA="$RELEASE_DIR/metadata" SECURITY="$RELEASE_DIR/security" SCRIPTS="$RELEASE_DIR/scripts" TOOLS="$RELEASE_DIR/tools" IMAGES="$RELEASE_DIR/images" set_color () { if [ "$COLOR" = "1" ] then color_start="\033[36m" color_end="\033[0m" else color_start="" color_end="" fi }