From f6861c095e1800b32963c55cce3d8530edf145da Mon Sep 17 00:00:00 2001 From: Matt Crees Date: Tue, 10 Oct 2023 15:48:48 +0100 Subject: [PATCH] WIP: allow unclean skc --- functions | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/functions b/functions index a0a3709..9d18f2f 100644 --- a/functions +++ b/functions @@ -597,9 +597,11 @@ function create_kayobe_environment { local kayobe_config_source_path=${2:-$KAYOBE_CONFIG_SOURCE_PATH} mkdir -p "$env"/{src/kayobe,src/kayobe-config,venvs/kayobe} - # Ensure we have an unmodified copy of kayobe-config - if [[ $(realpath "$kayobe_config_source_path") != $(realpath "$env/src/kayobe-config") ]]; then - clean_copy "$kayobe_config_source_path" "$env/src/kayobe-config" + if [ $KAYOBE_AUTOMATION_ALLOW_UNCLEAN_KAYOBE_CONFIG != true]; then + # Ensure we have an unmodified copy of kayobe-config + if [[ $(realpath "$kayobe_config_source_path") != $(realpath "$env/src/kayobe-config") ]]; then + clean_copy "$kayobe_config_source_path" "$env/src/kayobe-config" + fi fi if [ -f "$kayobe_config_source_path/requirements.txt" ]; then