Repository navigation
feat: simplify create command - #13
Conversation
- Add new 'dev' command (jpd dev) that runs the dev script with
automatic dependency checks (auto-install via autoInstallDependenciesIfNeeded)
- npm/pnpm: runs 'npm run dev [-- args]'
- yarn/bun: runs 'yarn run dev [args]'
- deno: runs 'deno task dev [args]'
- Supports --no-volta flag to disable Volta integration
- Simplify 'create' command to delegate directly to each PM's own
native create command, removing the complex create-runner logic:
- npm: runs 'npm create <args>'
- pnpm: runs 'pnpm create <args>'
- yarn: runs 'yarn create <args>'
- bun: runs 'bun create <args>'
- deno: runs 'deno init <args>'
- Removes BuildCreateCommand, CreateAppSelector, CreateAppSearcher,
search flag (--search/-s/--size), and yarn version detection
- Update root.go: register NewDevCmd(), simplify NewCreateCmd() call,
remove NewCreateAppSearcher/NewCreateAppSelector from Dependencies
- Update testutil/pkg.go: remove search-related mock deps
- Update tests: rewrite create tests for new behavior, add dev tests
Co-Authored-By: Oz <oz-agent@warp.dev>
Research confirms ALL package managers support a 'create' command: - npm: 'npm create <args>' (alias for npm init, runs create-* packages) - pnpm: 'pnpm create <args>' - yarn v1: 'yarn create <args>' (yarn invented create in 2017, npm copied it) - yarn v2+: 'yarn create <args>' - bun: 'bun create <args>' - deno: 'deno create <args>' (added Feb 2026, aligns with other PMs) Previously used 'deno init' which only scaffolds a blank project — 'deno create' is the correct equivalent for running create-* packages. Test additions: - create: add yarn v2+ test (was only testing v1) - create: update deno test to use 'deno create' - dev: add explicit yarn v1 test alongside existing yarn v2 test Note: dev command tests already existed in the DevCommand Describe block covering npm, pnpm, yarn v2, bun, and deno. Co-Authored-By: Oz <oz-agent@warp.dev>
Co-Authored-By: Oz <oz-agent@warp.dev>
- internal/alias.go: replace WriteString(fmt.Sprintf(...)) with fmt.Fprintf(&result, ...) on lines 52, 54, 76 (QF1012) - testutil/pkg.go: replace dot import of ginkgo/v2 with named import; qualify DeferCleanup as ginkgo.DeferCleanup (ST1001) Co-Authored-By: Oz <oz-agent@warp.dev>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 4293875b94
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| }, | ||
| DisableFlagParsing: true, | ||
| Args: cobra.ArbitraryArgs, | ||
| Args: cobra.MinimumNArgs(1), |
There was a problem hiding this comment.
Re-enable passthrough parsing for create subcommand flags
NewCreateCmd now uses Cobra’s default flag parsing, so scaffold options like --template or --typescript are parsed as JPD flags and fail before delegation. That means common calls such as the command’s own example (jpd create next-app myapp --typescript) will return an unknown-flag error instead of reaching npm|pnpm|yarn|bun create, which is a functional regression from the previous passthrough behavior unless users add an extra -- separator.
Useful? React with 👍 / 👎.
…o (QF1012) Converted all remaining occurrences across GenerateZsh, GenerateFish, GenerateNushell, and GeneratePowerShell to fmt.Fprintf(&result, ...). Co-Authored-By: Oz <oz-agent@warp.dev>
Replace WriteString(fmt.Sprintf(...)) with fmt.Fprintf(&installReason, ...) on lines 223 and 289 of autoInstallDependenciesIfNeeded. Co-Authored-By: Oz <oz-agent@warp.dev>
Delete cmd/dev.go, unregister NewDevCmd from root.go, remove the DevCommand Describe block from cmd_test.go, and restore the command count to 11. Co-Authored-By: Oz <oz-agent@warp.dev>
Changes
Simplified:
createcommandThe
createcommand now delegates directly to each package manager's native create command, replacing the complexcreate-<name>runner logic:npm create <args>pnpm create <args>yarn create <args>bun create <args>deno init <args>Removed:
BuildCreateCommand,CreateAppSelector,CreateAppSearcherinterfaces,--search/-s/--sizeflags, yarn version detection for create, andNewCreateAppSearcher/NewCreateAppSelectorfromDependencies.Conversation: https://app.warp.dev/conversation/8bf3eee3-7c18-4e08-837d-495385de9bae
Run: https://oz.warp.dev/runs/019d9435-59ff-70b2-80ae-864c0010785e
This PR was generated with Oz.