Skip to content

Commit

Permalink
Fixing Env variables.
Browse files Browse the repository at this point in the history
  • Loading branch information
dictions committed Jun 2, 2016
1 parent d4e9a44 commit 11ce617
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions bin/compile
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,19 @@

BUILD_DIR=$1
CACHE_DIR=$2
ENV_DIR=$3
BUILDPACK_DIR=$(cd $(dirname $0); cd ..; pwd)
mkdir -p ${BUILD_DIR} ${CACHE_DIR}

# START CONFIG
# Support end-user configured CRAFT_VERSION, and CRAFT_BUILD
# This way, end-users can choose exactly which versions to run with.

# Set Craft Environment Variables
for KEY in CRAFT_VERSION CRAFT_BUILD; do
[ -f $ENV_DIR/$KEY ] && export "$KEY=$(cat $ENV_DIR/$KEY)"
done

if [ -z "$CRAFT_VERSION" ]; then
CRAFT_VERSION=2.6
fi
Expand Down

0 comments on commit 11ce617

Please sign in to comment.