Skip to content

fix: update web workflow #2

fix: update web workflow

fix: update web workflow #2

Workflow file for this run

on:
push:
paths: ['apps/web/**', '.github/workflows/web.yaml']
pull_request:
paths: ['apps/web/**']
jobs:
validate:
runs-on: ubuntu-latest
name: Validate
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Install Node.js
uses: actions/setup-node@v3
with:
node-version: 20
- name: Install pnpm
uses: pnpm/action-setup@v2
with:
version: 8
run_install: false
- name: Install packages
run: |
pnpm i
- name: Lint
run: |
pnpm run lint:web
- name: Test
run: |
pnpm run test:web
deploy:
if: github.ref == 'refs/heads/main'
runs-on: ubuntu-latest
name: Lint
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Install packages
run: |
pnpm i
- name: Build
run: |
pnpm run build:web
- name: Deploy
run: |
pnpm install --global vercel
vercel pull --yes --environment=production --token=${{ secrets.VERCEL_TOKEN }}
vercel build --prod --token=${{ secrets.VERCEL_TOKEN }}
vercel deploy --prebuilt --prod --token=${{ secrets.VERCEL_TOKEN }}