honojs / create-hono

CLI for creating a Hono app
41 stars 12 forks source link

Hide dependency option if no package manager exists #45

Closed ryuapp closed 1 month ago

ryuapp commented 1 month ago

If no package manager exists, it is preferable that the dependency option doesn't appear. There are few users who only use Deno, but it's better not to get errors.

C:\Users\xxx\works>deno run -A npm:create-hono
create-hono version 0.8.0
? Which template do you want to use? cloudflare-pages
✔ Cloning the template
? Do you want to install project dependencies? yes

error: Uncaught (in promise) Error: Error running hook for cloudflare-pages: [select prompt] No selectable choices. All choices are disabled.
    at main (file:///C:/Users/xxx/works/AppData/Local/deno/npm/registry.npmjs.org/create-hono/0.8.0/bin:22389:11)
    at eventLoopTick (ext:core/01_core.js:168:7)

Related: #42

yusukebe commented 1 month ago

Thanks @ryuapp Indeed, you are right.

@6km How do you think about it?

6km commented 1 month ago

@yusukebe It's better for developer experience. I can work on a PR.