From 19565cc4ab18cf31ab6e0a7f4cc534f820a179b7 Mon Sep 17 00:00:00 2001 From: Nicola Delfino Date: Thu, 1 Aug 2024 10:51:23 +0200 Subject: [PATCH] Update azure-static-web-apps-calm-mushroom-0f7713e03.yml --- ...-static-web-apps-calm-mushroom-0f7713e03.yml | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/.github/workflows/azure-static-web-apps-calm-mushroom-0f7713e03.yml b/.github/workflows/azure-static-web-apps-calm-mushroom-0f7713e03.yml index 1021476..3cdc8a0 100644 --- a/.github/workflows/azure-static-web-apps-calm-mushroom-0f7713e03.yml +++ b/.github/workflows/azure-static-web-apps-calm-mushroom-0f7713e03.yml @@ -1,4 +1,4 @@ -name: Azure Static Web Apps CI/CD +name: deploy to Azure calm-mushroom on: push: @@ -19,6 +19,21 @@ jobs: with: submodules: true lfs: false + + - name: prepare build date in GITHUB_ENV + id: step_build_date_and_time + run: | + echo "build_timestamp=$(date)" >> $GITHUB_ENV + + - name: Use the build date from GITHUB_ENV + id: step_replace + # encode connection string with https://dwaves.de/tools/escape/ !! + run: | + build=$(date +%Y.%m.%d).github + echo "build date: ${{ env.build_timestamp }} - $build" + echo "build number: ${{ github.run_number }}" + sed -i "s/__BUILDDATE__/$build/g" index.html + sed -i 's/__BUILDNUMBER__/${{ github.run_number }}/g' index.html - name: Build And Deploy id: builddeploy uses: Azure/static-web-apps-deploy@v1