fix(deps): update dependency uuid to v10 #843
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Deploy to Azure Static Web Apps | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
types: [opened, synchronize, reopened, closed] | |
branches: | |
- main | |
permissions: | |
contents: read | |
pull-requests: write | |
jobs: | |
publish: | |
if: github.event_name == 'push' || (github.event_name == 'pull_request' && github.event.action != 'closed') | |
runs-on: ubuntu-latest | |
name: Build and Deploy to Azure SWA | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- uses: pnpm/action-setup@v4.0.0 | |
- name: Setup Node | |
uses: actions/setup-node@v4 | |
with: | |
node-version: 18.x | |
cache: "pnpm" | |
registry-url: https://registry.npmjs.org/ | |
- name: Install NPM Dependencies | |
run: pnpm install --frozen-lockfile | |
- name: Build | |
run: pnpm run build.azure | |
- name: Deploy | |
uses: Azure/static-web-apps-deploy@v1 | |
with: | |
azure_static_web_apps_api_token: ${{ secrets.AZURE_STATIC_WEB_APPS_API_TOKEN }} | |
repo_token: ${{ secrets.GITHUB_TOKEN }} # Used for Github integrations (i.e. PR comments) | |
action: "upload" | |
app_location: "dist" | |
api_location: "azure-functions" | |
skip_app_build: true | |
skip_api_build: true | |
delete_deployment: | |
if: github.event_name == 'pull_request' && github.event.action == 'closed' | |
runs-on: ubuntu-latest | |
name: Close Pull Request Job | |
steps: | |
- name: Close Pull Request | |
id: closepullrequest | |
uses: Azure/static-web-apps-deploy@v1 | |
with: | |
azure_static_web_apps_api_token: ${{ secrets.AZURE_STATIC_WEB_APPS_API_TOKEN }} | |
action: "close" |