这是indexloc提供的服务,不要输入任何密码
Skip to content

Deploy test

Deploy test #6

Workflow file for this run

# .github/workflows/preview.yml
name: PR Preview
on:
pull_request:
branches: [main]
# Permissions required by the Pages preview deployment
permissions:
pages: write
id-token: write
concurrency:
group: pr-preview-${{ github.event.pull_request.number }}
cancel-in-progress: true
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Use Node 20
uses: actions/setup-node@v4
with:
node-version: 20
cache: npm
- name: Install
run: npm ci
- name: Lint / Types / Tests
run: |
npm run lint
npm run type-check
npm test
# Build the site the same way your deploy script would build it
- name: Build
run: npm run build
- name: Upload Pages artifact
uses: actions/upload-pages-artifact@v3
with:
path: dist
deploy:
needs: build
runs-on: ubuntu-latest
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Deploy to GitHub Pages (preview)
id: deployment
uses: actions/deploy-pages@v4