Skip to content

fix(deps): update react monorepo to v19 (major) #804

fix(deps): update react monorepo to v19 (major)

fix(deps): update react monorepo to v19 (major) #804

Workflow file for this run

name: Release
on:
pull_request:
push:
branches:
- main
concurrency:
group: ${{ github.ref }}
cancel-in-progress: true
env:
NODE_VERSION: 18
NODE_CACHE: "yarn"
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }}
jobs:
setup:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3.5.3
- name: Setup Node
uses: actions/setup-node@v3.8.1
with:
node-version: ${{ env.NODE_VERSION }}
cache: ${{ env.NODE_CACHE }}
- name: Restore NextJs cache
uses: actions/cache@v3.3.1
with:
path: ${{ github.workspace }}/.next/cache
key: ${{ runner.os }}-nextjs-${{ hashFiles('**/yarn.lock') }}-${{ hashFiles('**/*.[jt]s', '**/*.[jt]sx') }}
restore-keys: |
${{ runner.os }}-nextjs-${{ hashFiles('**/yarn.lock') }}-
- name: Install dependencies
run: yarn install --frozen-lockfile
- name: Build application
run: yarn build
- name: Cache NextJs build
uses: actions/cache@v3.3.1
with:
path: ${{ github.workspace }}/.next
key: ${{ github.ref }}-${{ github.sha }}
test:
needs: setup
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v3.5.3
- name: Setup Node
uses: actions/setup-node@v3.8.1
with:
node-version: ${{ env.NODE_VERSION }}
cache: ${{ env.NODE_CACHE }}
- name: Install dependencies
run: yarn install --frozen-lockfile
- name: Check types
run: yarn type-check
- name: Check eslint
run: yarn lint
- name: Check prettier
run: yarn prettify
deploy:
needs: test
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/main'
steps:
- name: Checkout repository
uses: actions/checkout@v3.5.3
- name: Setup Node
uses: actions/setup-node@v3.8.1
with:
node-version: ${{ env.NODE_VERSION }}
cache: ${{ env.NODE_CACHE }}
- name: Install dependencies
run: yarn install --frozen-lockfile
- name: Restore cached NextJs build
uses: actions/cache@v3.3.1
with:
path: ${{ github.workspace }}/.next
key: ${{ github.ref }}-${{ github.sha }}
- name: Setup environment variables
run: yarn vercel pull --yes --environment=production --token=${{ secrets.VERCEL_TOKEN }}
- name: Prepare Vercel build
run: yarn vercel build --prod --token=${{ secrets.VERCEL_TOKEN }}
- name: Deploy NextJs application
run: yarn deploy --prod --token=${{ secrets.VERCEL_TOKEN }}