diff --git a/.github/workflows/flowzone.yml b/.github/workflows/flowzone.yml index 5a752108a..ebaa2c315 100644 --- a/.github/workflows/flowzone.yml +++ b/.github/workflows/flowzone.yml @@ -3500,25 +3500,22 @@ jobs: apiToken: ${{ secrets.CF_API_TOKEN }} accountId: ${{ secrets.CF_ACCOUNT_ID }} wranglerVersion: 3.5.1 - command: --version - postCommands: npx wrangler pages deploy --branch ${{ env.CF_BRANCH }} --project-name=${{ inputs.cloudflare_website }} build/ | tee -a $GITHUB_STEP_SUMMARY + command: pages deploy --branch ${{ env.CF_BRANCH }} --project-name=${{ inputs.cloudflare_website }} build/ - name: Find Cloudflare Pages link comment uses: peter-evans/find-comment@v3 id: find_cf_comment with: issue-number: ${{ github.event.pull_request.number }} - comment-author: flowzone-app[bot] body-includes: Website deployed to CF Pages, 👀 preview link - token: ${{ steps.gh_app_token.outputs.token || secrets.FLOWZONE_TOKEN }} - - name: Create or update Cloudflare Pages link comment + - name: Create or update Cloudflare Pages link comment if deployment link present uses: peter-evans/create-or-update-comment@v4 + if: steps.deploy_cf_pages.outputs.deployment-url != '' with: comment-id: ${{ steps.find_cf_comment.outputs.comment-id }} issue-number: ${{ github.event.pull_request.number }} + edit-mode: replace body: | Website deployed to CF Pages, 👀 preview link ${{ steps.deploy_cf_pages.outputs.deployment-url }} - edit-mode: replace - token: ${{ steps.gh_app_token.outputs.token || secrets.FLOWZONE_TOKEN }} github_clean: name: Clean GitHub release runs-on: ${{ fromJSON(inputs.runs_on) }} diff --git a/flowzone.yml b/flowzone.yml index 2e55e9df8..17b1537de 100644 --- a/flowzone.yml +++ b/flowzone.yml @@ -3289,28 +3289,24 @@ jobs: apiToken: ${{ secrets.CF_API_TOKEN }} accountId: ${{ secrets.CF_ACCOUNT_ID }} wranglerVersion: "3.5.1" # latest - https://www.npmjs.com/package/wrangler - command: --version - postCommands: npx wrangler pages deploy --branch ${{ env.CF_BRANCH }} --project-name=${{ inputs.cloudflare_website }} build/ | tee -a $GITHUB_STEP_SUMMARY + command: pages deploy --branch ${{ env.CF_BRANCH }} --project-name=${{ inputs.cloudflare_website }} build/ - name: Find Cloudflare Pages link comment uses: peter-evans/find-comment@v3 id: find_cf_comment with: issue-number: ${{ github.event.pull_request.number }} - comment-author: 'flowzone-app[bot]' body-includes: Website deployed to CF Pages, 👀 preview link - token: ${{ steps.gh_app_token.outputs.token || secrets.FLOWZONE_TOKEN }} - - name: Create or update Cloudflare Pages link comment + - name: Create or update Cloudflare Pages link comment if deployment link present uses: peter-evans/create-or-update-comment@v4 - # if: steps.deploy_cf_pages.outputs.deployment-url != '' + if: steps.deploy_cf_pages.outputs.deployment-url != '' with: comment-id: ${{ steps.find_cf_comment.outputs.comment-id }} issue-number: ${{ github.event.pull_request.number }} + edit-mode: replace body: | Website deployed to CF Pages, 👀 preview link ${{ steps.deploy_cf_pages.outputs.deployment-url }} - edit-mode: replace - token: ${{ steps.gh_app_token.outputs.token || secrets.FLOWZONE_TOKEN }} ################################################### # GitHub