diff --git a/.github/workflows/deploy-to-pages.yml b/.github/workflows/deploy-to-pages.yml index d012682..74670af 100644 --- a/.github/workflows/deploy-to-pages.yml +++ b/.github/workflows/deploy-to-pages.yml @@ -23,11 +23,11 @@ jobs: -H "Authorization: Bearer ${{ secrets.CLOUDFLARE_API_TOKEN }}") if [ $response -eq 404 ]; then echo "Project does not exist, creating..." - npx wrangler pages project create favicon --production-branch ${{ github.ref_name }} + npx wrangler pages project create favicon --production-branch main else echo "Project exists, skipping creation." fi - npm run pages:build && npx wrangler pages deploy --production-branch ${{ github.ref_name }} + npm run pages:build && npx wrangler pages deploy --branch ${{ github.ref_name }} env: CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }} CLOUDFLARE_ACCOUNT_ID: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }} diff --git a/.github/workflows/deploy-to-preview.yml b/.github/workflows/deploy-to-preview.yml index c3af63e..a3b7b1a 100644 --- a/.github/workflows/deploy-to-preview.yml +++ b/.github/workflows/deploy-to-preview.yml @@ -38,7 +38,7 @@ jobs: echo "Project exists, skipping creation." fi sed -i 's/favicon/favicon-preview/' wrangler.toml - npm run pages:build && npx wrangler pages deploy --production-branch main + npm run pages:build && npx wrangler pages deploy --branch main env: CLOUDFLARE_API_TOKEN: ${{ secrets.CLOUDFLARE_API_TOKEN }} CLOUDFLARE_ACCOUNT_ID: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}