From 77f25847226ed223609d4c5af2a3c4c150f59f1c Mon Sep 17 00:00:00 2001 From: becky-dt Date: Thu, 24 Aug 2023 13:58:59 +0100 Subject: [PATCH] added logic to makefile to check true/false input --- Makefile | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index cdb82930..ab15bcff 100644 --- a/Makefile +++ b/Makefile @@ -69,14 +69,19 @@ wait ?= false run: ## Run pipeline in sandbox environment. Must specify pipeline=. Optionally specify ENABLE_PIPELINE_CACHING= (defaults to default Vertex caching behaviour) and wait= (default = false). Set compile=false to skip recompiling the pipeline and set build=false to skip rebuilding container images @if [ $(compile) = "true" ]; then \ $(MAKE) compile ; \ + elif [ $(compile) != "false" ]; then \ + echo "ValueError: compile must be either true or false" ; \ + exit ; \ fi && \ if [ $(build) = "true" ]; then \ $(MAKE) build ; \ + elif [ $(build) != "false" ]; then \ + echo "ValueError: build must be either true or false" ; \ + exit ; \ fi && \ cd pipelines/src && \ poetry run python -m pipelines.utils.trigger_pipeline --template_path=pipelines/${pipeline}/pipeline.yaml --display_name=${pipeline} --wait=${wait} - test: ## Run unit tests for a specific component group or for all component groups and the pipeline trigger code. Specify GROUP= @if [ -n "${GROUP}" ]; then \ echo "Test components under components/${GROUP}" && \