Skip to content

feat(cli): add deno create command - #32225

Merged
dsherret merged 2 commits into
denoland:mainfrom
it-education-md:feat/cli-deno-create-npm-only
Feb 18, 2026
Merged

dsherret merged 2 commits into
denoland:mainfrom
it-education-md:feat/cli-deno-create-npm-only

Conversation

@it-education-md

@it-education-md it-education-md commented Feb 18, 2026 •

Copy link
Copy Markdown
Contributor

Closes #31793

Summary

  • Add deno create as a first-class CLI subcommand
  • Route it to the existing init package path (InitFlags.package)
  • Keep npm-only behavior for create (no JSR support yet).
  • Keep --npm support (similar to deno init) while also supporting explicit npm: package input.
  • Fix npm-prefixed normalization to avoid npm:create-npm:*

Test plan

  • cargo check -p deno passes
  • cargo test -p deno create --lib passes
  • cargo test -p deno npm_name_to_create_package_test --lib passes

Manual check

  • deno create --yes vite
    Parser error: Missing npm: prefix. For example: deno create npm:vite.
  • deno create --yes --npm vite
    Resolves to create-vite.
  • deno create --yes npm:vite
    Resolves to create-vite.
  • deno create --yes npm:vite my-project
    Parser error (missing -- before package args).
  • deno create --yes npm:vite -- my-project
    Resolves to create-vite with forwarded arg my-project.
  • deno create --yes jsr:@std/http
    Parser error: JSR packages are not supported by deno create yet. Use npm: or --npm.
  • deno create --yes --jsr @std/http
    Parser error: unexpected argument --jsr.
  • deno create --yes npm:
    Parser error: Missing package name after 'npm:' prefix.

@CLAassistant

CLAassistant commented Feb 18, 2026 •

Copy link
Copy Markdown

CLA assistant check
All committers have signed the CLA.

Comment thread cli/args/flags.rs Resolved
Comment thread cli/args/flags.rs Resolved
Comment thread cli/tools/init/mod.rs Resolved

@dsherret dsherret left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Thanks!

@dsherret dsherret changed the title feat(cli): Add npm-only deno create command feat(cli): add deno create command Feb 18, 2026
@dsherret
dsherret merged commit cad67da into denoland:main Feb 18, 2026
112 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.

deno create

3 participants