Skip to content

refactor: use github pages for deployment #7

refactor: use github pages for deployment

refactor: use github pages for deployment #7

Workflow file for this run

name: Deploy PR preview
on:
pull_request:
types:
- opened
- reopened
- synchronize
- closed
concurrency: preview-${{ github.ref }}
jobs:
deploy-preview:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Node
uses: actions/setup-node@v4
- name: Setup PNPM
uses: pnpm/action-setup@v4
with:
version: 8.15.7
run_install: true
- name: Build
run: pnpm build:preview
env:
VITE_BASE_URL: /sway-examples/pr-preview/${{ github.event.number }}
- name: Deploy preview
uses: rossjrw/pr-preview-action@v1
with:
source-dir: ./dist/
preview-branch: gh-pages
umbrella-dir: pr-preview
action: deploy