File tree Expand file tree Collapse file tree 1 file changed +12
-5
lines changed Expand file tree Collapse file tree 1 file changed +12
-5
lines changed Original file line number Diff line number Diff line change @@ -658,6 +658,10 @@ function getFullCustomCommand(customCommand: string, pkgInfo?: PkgInfo) {
658658 if ( pkgManager === 'bun' ) {
659659 return 'bun x create-'
660660 }
661+ // Deno uses `run -A npm:create-` instead of `create` or `init` to also provide needed perms
662+ if ( pkgManager === 'deno' ) {
663+ return 'deno run -A npm:create-'
664+ }
661665 // pnpm doesn't support the -- syntax
662666 if ( pkgManager === 'pnpm' ) {
663667 return 'pnpm create '
@@ -669,20 +673,23 @@ function getFullCustomCommand(customCommand: string, pkgInfo?: PkgInfo) {
669673 } )
670674 // Only Yarn 1.x doesn't support `@version` in the `create` command
671675 . replace ( '@latest' , ( ) => ( isYarn1 ? '' : '@latest' ) )
672- . replace ( / ^ n p m e x e c / , ( ) => {
676+ . replace ( / ^ n p m e x e c / , ( ) => {
673677 // Prefer `pnpm dlx`, `yarn dlx`, or `bun x`
674678 if ( pkgManager === 'pnpm' ) {
675- return 'pnpm dlx'
679+ return 'pnpm dlx '
676680 }
677681 if ( pkgManager === 'yarn' && ! isYarn1 ) {
678- return 'yarn dlx'
682+ return 'yarn dlx '
679683 }
680684 if ( pkgManager === 'bun' ) {
681- return 'bun x'
685+ return 'bun x '
686+ }
687+ if ( pkgManager === 'deno' ) {
688+ return 'deno run -A npm:'
682689 }
683690 // Use `npm exec` in all other cases,
684691 // including Yarn 1.x and other custom npm clients.
685- return 'npm exec'
692+ return 'npm exec '
686693 } )
687694 )
688695}
You can’t perform that action at this time.
0 commit comments