Docs #106
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI | |
| on: | |
| pull_request: | |
| branches: ["*"] | |
| push: | |
| branches: ["main", "changesets/release"] | |
| merge_group: | |
| workflow_dispatch: | |
| inputs: | |
| pr_number: | |
| description: "PR number to run CI for" | |
| required: false | |
| type: string | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: ${{ github.ref != 'refs/heads/main' }} | |
| permissions: | |
| contents: read | |
| pull-requests: read | |
| checks: write | |
| statuses: write | |
| # You can leverage Vercel Remote Caching with Turbo to speed up your builds | |
| # @link https://turborepo.org/docs/core-concepts/remote-caching#remote-caching-on-vercel-builds | |
| env: | |
| FORCE_COLOR: 3 | |
| jobs: | |
| lint: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup | |
| uses: ./.github/setup | |
| - name: Generate prisma client | |
| run: pnpm -F adapter-prisma prisma:generate | |
| - name: Lint | |
| run: pnpm lint | |
| format: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup | |
| uses: ./.github/setup | |
| - name: Format | |
| run: pnpm format | |
| typecheck: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup | |
| uses: ./.github/setup | |
| - name: Generate prisma client | |
| run: pnpm -F adapter-prisma prisma:generate | |
| - name: Typecheck | |
| run: pnpm typecheck | |
| unittest: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| node-version: [20, 22] | |
| name: Test (Node.js ${{ matrix.node-version }}) | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup Node.js ${{ matrix.node-version }} | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: ${{ matrix.node-version }} | |
| - name: Setup pnpm | |
| uses: pnpm/action-setup@v4 | |
| with: | |
| version: 10.13.1 | |
| run_install: false | |
| - shell: bash | |
| run: pnpm install | |
| - name: Build packages | |
| run: | | |
| pnpm -F adapter-prisma prisma:generate | |
| pnpm --filter "./packages/*" build | |
| - name: Test Core Package | |
| run: pnpm test:core | |
| - name: Test Drizzle PostgreSQL (PGlite) | |
| run: pnpm test:drizzle | |
| - name: Test Prisma (Testcontainers - Postgres) | |
| run: | | |
| pnpm -F adapter-prisma prisma:generate | |
| pnpm test:prisma | |
| env: | |
| # Ensure Docker is available for Testcontainers | |
| TESTCONTAINERS_RYUK_DISABLED: true | |
| pkg-new-release: | |
| needs: [lint, format, typecheck, unittest] | |
| if: github.event_name == 'pull_request' | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup | |
| uses: ./.github/setup | |
| - name: Generate prisma client | |
| run: pnpm -F adapter-prisma prisma:generate | |
| - name: Build | |
| run: pnpm build:pkg | |
| - run: pnpx pkg-pr-new publish ./packages/* |