From 520cf4cc1a882849808ef37701cfdf750d5a63a6 Mon Sep 17 00:00:00 2001 From: Nicolas Meienberger Date: Sun, 19 May 2024 13:54:18 +0200 Subject: [PATCH] chore: format only if compose file exists --- .github/workflows/renovate-app-version.sh | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.github/workflows/renovate-app-version.sh b/.github/workflows/renovate-app-version.sh index 0ceefe27..67d86905 100755 --- a/.github/workflows/renovate-app-version.sh +++ b/.github/workflows/renovate-app-version.sh @@ -43,6 +43,7 @@ do # apply trimmed version to docker-compose.json's main service contents="$(jq --arg image "$image" --arg main_service_index "$main_service_index" '.services[$main_service_index | tonumber].image=$image' "$compose_file")" echo "${contents}" > "$compose_file" + npx prettier "$compose_file" --write fi # ------------------- Update config.json ------------------- @@ -50,9 +51,6 @@ do tipi_version=$((tipi_version + 1)) contents="$(jq --argjson tipi_version $tipi_version '.tipi_version=$tipi_version' "$config_file")" echo "${contents}" > "$config_file" - - # ------------------- Format files with prettier ------------------- npx prettier "$config_file" --write - npx prettier "$compose_file" --write fi done