Skip to content

fix(deploy) Preview deploy settings before prompting for customization#55

Merged
luanvdw merged 1 commit into
mainfrom
feat/deploy-settings-preview
Jun 1, 2026
Merged

fix(deploy) Preview deploy settings before prompting for customization#55
luanvdw merged 1 commit into
mainfrom
feat/deploy-settings-preview

Conversation

@luanvdw
Copy link
Copy Markdown
Member

@luanvdw luanvdw commented Jun 1, 2026

What changed

  • Shows a concise detected deploy settings preview before the first-run customization prompt.
  • Compresses the preview to Detected <framework> plus framework/runtime rows.
  • Renames the prompt to Customize build settings? and removes the build command row for now.
  • Updates product docs and adds controller coverage for the prompt ordering.

Why

After Project setup, app deploy asked whether users wanted to customize settings before showing what defaults had been detected. The new preview makes the prompt less of a black box while keeping the setup path compact.

Local review

  • Thermonuclear review: pass after aligning prompt copy to the requested UX.
  • File-size gate: pass. No changed file crossed 1000 lines; existing large controller/test files grew only in the narrow deploy path and its test.

Validation

  • pnpm --filter @prisma/cli exec vitest run tests/app-controller.test.ts
  • pnpm --filter @prisma/cli build
  • pnpm --filter @prisma/cli test

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Jun 1, 2026

Review Change Stack

Walkthrough

This PR adds a detected build-settings preview to the prisma-cli app deploy interactive flow. When users deploy an app for the first time, the CLI now displays the inferred framework and runtime before asking whether to customize the build settings. The rendering contract, controller integration, and test coverage are included.

Changes

Deploy Settings Preview Feature

Layer / File(s) Summary
Deploy settings preview rendering contract and implementation
packages/cli/src/lib/app/deploy-output.ts
New DeploySettingsPreviewRow interface with key and value fields, DEPLOY_SETTINGS_MIN_KEY_WIDTH constant, and renderDeploySettingsPreview function that formats detected settings with left-padded keys using ui.accent, vertical rail using ui.dim, and bolded values using ui.strong.
Controller integration and prompt update
packages/cli/src/controllers/app.ts
Imports renderDeploySettingsPreview, introduces maybeRenderDeploySettingsPreview helper that conditionally writes detected framework/runtime to stderr when not in --json or --quiet modes, calls this helper before the customization prompt, and updates the prompt text from "Customize settings?" to "Customize build settings?".
Documentation and test coverage
docs/product/command-spec.md, docs/product/output-conventions.md, packages/cli/tests/app-controller.test.ts
Command spec updated to reflect the new prompt wording and that detected settings are previewed before prompting; output conventions documentation includes an example of the detected Next.js framework/runtime display; new test verifies that inferred buildType and portMapping are passed to the deployment provider and that stderr output shows detected settings before the customization prompt.

🎯 2 (Simple) | ⏱️ ~12 minutes

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description check ✅ Passed The description is well-structured and directly related to the changeset, covering what changed, why it matters, and validation steps performed.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Title check ✅ Passed The title accurately and specifically describes the main change: adding a preview of deploy settings before the customization prompt.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch feat/deploy-settings-preview
✨ Simplify code
  • Create PR with simplified code
  • Commit simplified code in branch feat/deploy-settings-preview

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@luanvdw luanvdw marked this pull request as ready for review June 1, 2026 07:59
@luanvdw luanvdw changed the title [codex] Preview deploy settings before customization fix(deploy) Preview deploy settings before prompting for customization Jun 1, 2026
@luanvdw luanvdw merged commit c2517f5 into main Jun 1, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant