From 13623a6a0840bde2c32ec4d72bffc55ff2bf70f5 Mon Sep 17 00:00:00 2001 From: Eli Uriegas Date: Mon, 15 Jul 2019 20:22:14 +0000 Subject: [PATCH] Change enbsubst to substitute for new COMMIT_SHA var Signed-off-by: Eli Uriegas --- Makefile | 4 ++-- install.sh | 4 +--- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/Makefile b/Makefile index e72db3c..33017cf 100644 --- a/Makefile +++ b/Makefile @@ -6,14 +6,14 @@ VOLUME_MOUNTS=-v "$(CURDIR)":/v SHELLCHECK_EXCLUSIONS=$(addprefix -e, SC1091 SC1117) SHELLCHECK=docker run --rm $(VOLUME_MOUNTS) -w /v koalaman/shellcheck $(SHELLCHECK_EXCLUSIONS) -ENVSUBST_VARS=SCRIPT_COMMIT_SHA +ENVSUBST_VARS=LOAD_SCRIPT_COMMIT_SHA .PHONY: build build: build/install.sh build/install.sh: install.sh mkdir -p $(@D) - SCRIPT_COMMIT_SHA='$(shell git rev-parse HEAD)' envsubst '$(addprefix $$,$(ENVSUBST_VARS))' < $< > $@ + LOAD_SCRIPT_COMMIT_SHA='$(shell git rev-parse HEAD)' envsubst '$(addprefix $$,$(ENVSUBST_VARS))' < $< > $@ .PHONY: shellcheck shellcheck: build/install.sh diff --git a/install.sh b/install.sh index 60cf261..b72f5a2 100644 --- a/install.sh +++ b/install.sh @@ -16,9 +16,7 @@ set -e # # Git commit from https://github.com/docker/docker-install when # the script was uploaded (Should only be modified by upload job): - -# shellcheck disable=SC2140 -SCRIPT_COMMIT_SHA="${SCRIPT_COMMIT_SHA}" +SCRIPT_COMMIT_SHA="${LOAD_SCRIPT_COMMIT_SHA}" # The channel to install from: