Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
17 commits
Select commit Hold shift + click to select a range
55783f6
feat: typed prisma.compute.ts compute config
AmanVarshney01 Jun 12, 2026
6383c70
chore: drop unused c12 dependency, add cross-OS test workflow
AmanVarshney01 Jun 12, 2026
b45f6d3
ci: skip agent skills installation in CI installs
AmanVarshney01 Jun 12, 2026
22c1a80
test: make the suite Windows-portable
AmanVarshney01 Jun 12, 2026
da8f546
test: run repo scripts as subprocesses; fix mixed-separator path display
AmanVarshney01 Jun 12, 2026
17bf777
review: address CodeRabbit findings
AmanVarshney01 Jun 12, 2026
31de4a5
docs: clarify pin and state-cache anchoring semantics
AmanVarshney01 Jun 12, 2026
0d63d41
fix: reject Windows drive-relative paths in normalizeRelativePath
AmanVarshney01 Jun 12, 2026
570b21f
feat: add nuxt and astro to the framework registry
AmanVarshney01 Jun 12, 2026
af6ae14
feat: consume the compute config contract from @prisma/compute-sdk/co…
AmanVarshney01 Jun 12, 2026
fc3edb4
fix: apply committed build blocks under auto detection, doc fixes fro…
AmanVarshney01 Jun 12, 2026
ea43fa6
Merge origin/main (expanded Biome lint rules) into feat/prisma-comput…
AmanVarshney01 Jun 12, 2026
eb44109
fix: clear type errors gated by the new CI Type Check job
AmanVarshney01 Jun 12, 2026
ac2c517
fix: resolve the Git branch from the nearest repository upward
AmanVarshney01 Jun 12, 2026
42aaa72
fix: drop repo-internal docs path from app logs output
AmanVarshney01 Jun 12, 2026
d6b8ad6
fix: name the target in deploy-all per-app logs hints
AmanVarshney01 Jun 12, 2026
3f122a2
fix: name a target in the deploy-all list-deploys suggestion
AmanVarshney01 Jun 12, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
57 changes: 57 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
name: Test

on:
push:
branches:
- main
pull_request:

concurrency:
group: test-${{ github.ref }}
cancel-in-progress: true

jobs:
test:
strategy:
fail-fast: false
matrix:
os:
- ubuntu-latest
- windows-latest
runs-on: ${{ matrix.os }}
permissions:
contents: read

steps:
- uses: actions/checkout@93cb6efe18208431cddfb8368fd83d5badbf9bfd
with:
persist-credentials: false

- uses: actions/setup-node@48b55a011bda9f5d6aeb4c2d9c7362e8dae4041e
with:
node-version: 24

- name: Enable pnpm
shell: bash
run: |
corepack enable
PNPM_VERSION="$(node -p 'const pm = require("./package.json").packageManager; const match = pm && pm.match(/^pnpm@(.+)$/); if (!match) throw new Error("packageManager must be pnpm@<version>"); match[1]')"
corepack prepare "pnpm@${PNPM_VERSION}" --activate
echo "PNPM_STORE_PATH=$(pnpm store path)" >> "$GITHUB_ENV"

- name: Cache pnpm store
uses: actions/cache@0057852bfaa89a56745cba8c7296529d2fc39830
with:
path: ${{ env.PNPM_STORE_PATH }}
key: pnpm-store-${{ runner.os }}-${{ hashFiles('pnpm-lock.yaml') }}
restore-keys: |
pnpm-store-${{ runner.os }}-

- name: Install dependencies
run: pnpm install --frozen-lockfile

- name: Run CLI tests
run: pnpm --filter @prisma/cli test

- name: Build CLI
run: pnpm --filter @prisma/cli build
149 changes: 114 additions & 35 deletions docs/product/command-spec.md

Large diffs are not rendered by default.

12 changes: 10 additions & 2 deletions docs/product/error-conventions.md
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,11 @@ These codes are the minimum stable set for the MVP:
- `LOCAL_STATE_WRITE_FAILED`
- `LOCAL_STATE_STALE`
- `BRANCH_NOT_DEPLOYABLE`
- `APP_CONFIG_INVALID`
- `COMPUTE_CONFIG_INVALID`
- `COMPUTE_CONFIG_TARGET_REQUIRED`
- `COMPUTE_CONFIG_TARGET_UNKNOWN`
- `BUILD_SETTINGS_MIGRATION_REQUIRED`
- `BUILD_SETTINGS_UNSUPPORTED`
- `FRAMEWORK_NOT_DETECTED`
- `DEPLOYMENT_NOT_FOUND`
- `NO_DEPLOYMENTS`
Expand Down Expand Up @@ -223,7 +227,11 @@ Recommended meanings:
- `LOCAL_STATE_WRITE_FAILED`: the CLI could not save local Project binding state such as `.prisma/local.json` or the matching `.gitignore` entry; callers should fix directory permissions or filesystem state before retrying
- `LOCAL_STATE_STALE`: local Project pin no longer matches platform data and continuing would be ambiguous
- `BRANCH_NOT_DEPLOYABLE`: command tried to deploy to a non-deployable branch context
- `APP_CONFIG_INVALID`: `prisma.app.json` is missing required build settings, has invalid JSON, or points outside the app root
- `COMPUTE_CONFIG_INVALID`: `prisma.compute.ts` failed to load or validate
- `COMPUTE_CONFIG_TARGET_REQUIRED`: a multi-app compute config needs an `[app]` target and none was given or inferred
- `COMPUTE_CONFIG_TARGET_UNKNOWN`: the `[app]` target matches no configured app
- `BUILD_SETTINGS_MIGRATION_REQUIRED`: a legacy `prisma.app.json` contains custom build settings that must move into the `build` block of `prisma.compute.ts`
- `BUILD_SETTINGS_UNSUPPORTED`: a compute config `build` block targets a framework whose strategy owns its build (nuxt, astro)
- `FRAMEWORK_NOT_DETECTED`: app deploy could not detect a supported Beta framework and no explicit framework/build type was provided
- `DEPLOYMENT_NOT_FOUND`: requested deployment id does not exist
- `NO_DEPLOYMENTS`: command resolved a branch or app but found no deployments
Expand Down
2 changes: 1 addition & 1 deletion docs/product/output-conventions.md
Original file line number Diff line number Diff line change
Expand Up @@ -338,7 +338,7 @@ Examples:
- `app deploy` should state the resolved target that matters in the current slice
- first local `app deploy` binding should make the Project choice explicit before work begins
- subsequent `app deploy` calls should use a compact target header such as `Deploying ./j1 to j1 / main / j1`
- config-backed `app deploy` builds should show whether they created or used `prisma.app.json` before build starts: `Build Command` with its source when inferred, and `Output Directory` as a literal path such as `.next/standalone` rather than an opaque framework default label
- config-backed `app deploy` builds should show the resolved build settings before build starts: `Build Command` and `Output Directory` with their sources (`prisma.compute.ts` or inference), `Output Directory` as a literal path such as `.next/standalone` rather than an opaque framework default label
- `app logs` should state the deployment it resolved
- `app list-deploys` should state which app or branch is being listed

Expand Down
6 changes: 3 additions & 3 deletions docs/product/resource-model.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,8 @@ Rules:

- `project` is not the same thing as `app`
- Public Beta does not read or write committed config files such as `prisma.config.ts` or `.prisma/settings.json` for project resolution
- `.prisma/local.json` is a gitignored local pin/cache for Workspace and Project IDs; it is not a declarative repo config file
- `prisma.app.json` is a committed app build-settings file only; it must not contain Workspace, Project, Branch, App, env, or secret resolution state
- `.prisma/local.json` is a gitignored local pin/cache for Workspace and Project IDs; it is not a declarative repo config file. When a `prisma.compute.ts` is discovered (nearest config from the invocation directory up to the repository or workspace root), the pin and the CLI state cache (`.prisma/cli/state.json`) are read and written in the config file's directory; without a config they stay in the invocation directory
- `prisma.compute.ts` is a committed deploy-defaults file; it must not contain Workspace, Project, Branch, env-secret, or credential resolution state
- Project setup is explicit: users choose an existing Project or explicitly create a new one before remote work starts
- `app deploy` may orchestrate Project setup, but it must not silently choose or create Project scope
- everything under a project happens in a branch
Expand Down Expand Up @@ -104,7 +104,7 @@ Rules:
- the runtime app service is scoped by branch in the platform model
- the app may be selected or created as part of app deployment workflows
- app selection is local CLI state when needed for the beta package
- app build settings may live in `prisma.app.json` beside `package.json`; v1 fields are `buildCommand` and `outputDirectory`
- app build settings live in the `build` block of `prisma.compute.ts` (`command`, `outputDirectory`); `prisma.app.json` is legacy and no longer read

### Deployment

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
"lint": "biome check .",
"lint:fix": "biome check . --write",
"lint:skills": "node scripts/validate-skills.mjs",
"prepare": "skills add ./skills --skill '*' --agent universal claude-code -y",
"prepare": "node scripts/prepare-skills.mjs",
"prepare:cli-publish": "node scripts/prepare-cli-publish.mjs",
"smoke:cli-nextjs": "node scripts/smoke-cli-nextjs-artifact.mjs",
"test:skills": "node --test scripts/validate-skills.test.mjs",
Expand Down
6 changes: 4 additions & 2 deletions packages/cli/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,9 @@
"bin": {
"prisma-cli": "./dist/cli.js"
},
"exports": {
"./package.json": "./package.json"
},
"files": [
"dist",
"README.md",
Expand Down Expand Up @@ -41,11 +44,10 @@
},
"dependencies": {
"@clack/prompts": "^1.5.0",
"@prisma/compute-sdk": "^0.22.0",
"@prisma/compute-sdk": "^0.23.0",
"@prisma/credentials-store": "^7.8.0",
"@prisma/management-api-sdk": "^1.37.0",
"better-result": "^2.9.2",
"c12": "4.0.0-beta.5",
"colorette": "^2.0.20",
"commander": "^14.0.3",
"dotenv": "^17.4.2",
Expand Down
Loading