diff --git a/sync-files/action.yaml b/sync-files/action.yaml index 49b6c9ea..93289d61 100644 --- a/sync-files/action.yaml +++ b/sync-files/action.yaml @@ -103,7 +103,10 @@ runs: pre_commands=$(yq ".pre-commands" /tmp/file-config.yaml) post_commands=$(yq ".post-commands" /tmp/file-config.yaml) - modified_source_path="/tmp/repository/$source_path" + full_source_path="/tmp/repository/$source_path" + + modified_source_path=$(mktemp) + cp "$full_source_path" "$modified_source_path" pre_commands=$(echo "$pre_commands" | sed "s|{source}|$modified_source_path|g" | sed "s|{dest}|$dest_path|g") post_commands=$(echo "$post_commands" | sed "s|{source}|$modified_source_path|g" | sed "s|{dest}|$dest_path|g")