Skip to content

fixing yarn.lock to fix CI #267

fixing yarn.lock to fix CI

fixing yarn.lock to fix CI #267

Workflow file for this run

name: Build & Generate Types
on: [push, pull_request] # Run on Push and Pull Requests
jobs:
build:
name: Build
timeout-minutes: 15
runs-on: ubuntu-latest
services:
postgres:
image: postgres:11
env:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
POSTGRES_DB: ci_db_test
ports:
- 5432:5432
options: --health-cmd pg_isready --health-interval 10s --health-timeout 5s --health-retries 5
env:
DATABASE_URL: postgresql://postgres:postgres@postgres:5432/ci_db_test
RESEND_API_KEY: "..."
COHERE_API_KEY: "..."
UPSTASH_REDIS_REST_URL: ""
UPSTASH_REDIS_REST_TOKEN: ""
STRIPE_PUBLIC_KEY: ${{ secrets.STRIPE_PUBLIC_KEY }}
STRIPE_SECRET_KEY: ${{ secrets.STRIPE_SECRET_KEY }}
steps:
- name: Check out code
uses: actions/checkout@v3
with:
fetch-depth: 2
- uses: actions/cache@v3
with:
# See here for caching with `yarn` https://github.com/actions/cache/blob/main/examples.md#node---yarn or you can leverage caching with actions/setup-node https://github.com/actions/setup-node
path: |
~/.npm
${{ github.workspace }}/.next/cache
# Generate a new cache whenever packages or source files change.
key: ${{ runner.os }}-nextjs-${{ hashFiles('**/package-lock.json') }}-${{ hashFiles('**.[jt]s', '**.[jt]sx') }}
# If source files changed but packages didn't, rebuild from a prior cache.
restore-keys: |
${{ runner.os }}-nextjs-${{ hashFiles('**/package-lock.json') }}-
- name: Setup Node.js environment
uses: actions/setup-node@v3
with:
node-version: 20
cache: "npm"
- name: Install dependencies
run: yarn install
- name: Generate Types
run: yarn prisma generate
- name: Build
run: yarn build
- name: Types
run: yarn types