Skip to content

feat: support deno create for project initialization#3706

Merged
bartlomieju merged 1 commit into
mainfrom
feat/deno-create-support
Mar 28, 2026
Merged

feat: support deno create for project initialization#3706
bartlomieju merged 1 commit into
mainfrom
feat/deno-create-support

Conversation

@bartlomieju
Copy link
Copy Markdown
Contributor

Summary

  • Add a ./create export to @fresh/init so users can scaffold projects with deno create @fresh/init (Deno 2.7+)
  • The old deno run -Ar jsr:@fresh/init continues to work but now shows a deprecation warning

New way (Deno 2.7+):

deno create @fresh/init

Old way (still works, with warning):

deno run -Ar jsr:@fresh/init

Test plan

  • deno lint and deno fmt clean
  • deno create @fresh/init scaffolds a project correctly (requires Deno 2.7+)
  • deno run -Ar jsr:@fresh/init still works and shows deprecation warning

🤖 Generated with Claude Code

Add a ./create export to @fresh/init so users can scaffold projects
with `deno create @fresh/init` (Deno 2.7+). The old invocation
`deno run -Ar jsr:@fresh/init` continues to work but now shows a
deprecation warning directing users to the new approach.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Comment thread packages/init/src/mod.ts
// deno-lint-ignore no-console
console.warn(
"\x1b[33m%s\x1b[0m",
`Warning: "deno run -Ar jsr:@fresh/init" is deprecated. Use "deno create @fresh/init" instead.`,
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.

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.

Or is that done in #3712?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Neither, this PR hasn't landed yet

@bartlomieju bartlomieju merged commit b790c80 into main Mar 28, 2026
8 checks passed
@bartlomieju bartlomieju deleted the feat/deno-create-support branch March 28, 2026 15:38
@AgnimaGocran
Copy link
Copy Markdown

In the last fresh version of Deno the command not working:

deno -v
deno 2.7.14
deno create @fresh/init
error: Missing `jsr:` or `npm:` prefix. For example: `deno create npm:vite`.

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.

4 participants