Add deployment strategy configuration and GitHub Actions CI/CD workflows#8
Merged
Merged
Conversation
Introduces a --deployment <vercel|none> flag (with an interactive prompt fallback) so scaffolded projects get their CI/CD wired up at creation time. Always emits .github/workflows/ci.yml and migrate-production.yml, and additionally writes vercel.json plus a publish-to-vercel job when the strategy is "vercel". The CI workflow triggers on PRs and pushes to main/feature/*/claude/*/fix/*, and the publish/migrate jobs are gated to pushes on main.
Parameterizes scripts/test.sh to take the deployment strategy as an argument (default 'vercel') and adds branch-specific assertions for vercel.json and the publish-to-vercel CI job. Runs the matrix [vercel, none] in the CLI's own CI so both code paths are exercised on every push.
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This PR adds support for configurable deployment strategies and scaffolds GitHub Actions CI/CD workflows during project initialization. Users can now choose between Vercel and no deployment strategy, with corresponding workflow files and configuration generated automatically.
Key Changes
--deploymentCLI option supporting "vercel" or "none" strategies with interactive prompts for user inputci.ymlworkflow that runs build, typecheck, and conditionally deploys to Vercel on main branch pushesmigrate-production.ymlreusable workflow for running database migrations with production secretsvercel.jsonconfiguration file generation when Vercel deployment is selectedscaffold()function to generate.github/workflows/directory and deployment-specific filesImplementation Details
z.enum(["vercel", "none"]))publish-to-verceljob only when deployment strategy is "vercel"workflow_callfor reusabilityhttps://claude.ai/code/session_013iTwmsSWk3jF7u5XZWEQkV