Skip to content

Bump vite from 4.5.1 to 4.5.2 (#7) #44

Bump vite from 4.5.1 to 4.5.2 (#7)

Bump vite from 4.5.1 to 4.5.2 (#7) #44

name: Run tests, build static files and deploy to GitHub Pages
on: [workflow_dispatch, push]
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: "18"
- run: yarn install --frozen-lockfile
- run: yarn typecheck
- run: yarn prettier --check src
- run: yarn build
if: github.ref != 'refs/heads/main'
build:
if: github.ref == 'refs/heads/main'
runs-on: ubuntu-latest
permissions:
contents: read
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: "18"
- name: Build static files
run: |
yarn install --frozen-lockfile
yarn build
- uses: actions/configure-pages@v3
- name: Upload static files to GitHub Pages
uses: actions/upload-pages-artifact@v2
with:
path: "dist"
deploy:
if: github.ref == 'refs/heads/main'
needs: [test, build]
runs-on: ubuntu-latest
permissions:
pages: write
id-token: write
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v2