From 40847c7763d7ecabc0251d0d1f7877ba31f93e04 Mon Sep 17 00:00:00 2001 From: Nicola Corna Date: Tue, 30 May 2017 21:43:54 +0200 Subject: [PATCH] Add RELEASE_TYPE --- Dockerfile | 3 +++ src/build.sh | 4 ++++ 2 files changed, 7 insertions(+) diff --git a/Dockerfile b/Dockerfile index 1f39115..e0df7ce 100644 --- a/Dockerfile +++ b/Dockerfile @@ -28,6 +28,9 @@ ENV BRANCH_NAME 'cm-14.1' # eg. DEVICE_LIST=hammerhead,bullhead,angler ENV DEVICE_LIST '' +# Release type string +ENV RELEASE_TYPE 'UNOFFICIAL' + # OTA URL that will be used inside CMUpdater # Use this in combination with LineageOTA to make sure your device can auto-update itself from this buildbot ENV OTA_URL '' diff --git a/src/build.sh b/src/build.sh index e312600..5e3d6ee 100755 --- a/src/build.sh +++ b/src/build.sh @@ -70,6 +70,10 @@ if ! [ -z "$DEVICE_LIST" ]; then echo ">> [$(date)] Preparing build environment" >> $DOCKER_LOG source build/envsetup.sh 2>&1 >&$DEBUG_LOG + echo ">> [$(date)] Setting \"$RELEASE_TYPE\" as release type" >> $DOCKER_LOG + sed -i '/#.*Filter out random types/d' vendor/cm/config/common.mk + sed -i '/$(filter .*$(CM_BUILDTYPE)/,+3d' vendor/cm/config/common.mk + # Set a custom updater URI if a OTA URL is provided if ! [ -z "$OTA_URL" ]; then echo ">> [$(date)] Adding OTA URL '$OTA_URL' to build.prop" >> $DOCKER_LOG