Skip to content

Commit

Permalink
🩹 fix(patch): create-bud-app fails when no dependencies are selected (#…
Browse files Browse the repository at this point in the history
…2404)

If no dependencies are selected `create-bud-app` will fail on installation step.

## Type of change

**PATCH: backwards compatible change**
  • Loading branch information
kellymears committed Aug 14, 2023
1 parent 3184d77 commit 43e59ce
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions sources/create-bud-app/src/tasks/install.dev.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@ export default async function installTask(command: CreateCommand) {
const spinner = command.createSpinner()
spinner.start(`Installing development dependencies...`)

if (!command.dependencies?.length) {
return spinner.succeed(`No development dependencies to install.`)
}

try {
const formatSignifier = createSignifierFormatter(command)

Expand Down
4 changes: 4 additions & 0 deletions sources/create-bud-app/src/tasks/install.prod.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@ export default async function installTask(command: CreateCommand) {
const spinner = command.createSpinner()
spinner.start(`Installing runtime dependencies...`)

if (!command.dependencies?.length) {
return spinner.succeed(`No runtime dependencies to install.`)
}

try {
switch (command.packageManager) {
case `npm`:
Expand Down

0 comments on commit 43e59ce

Please sign in to comment.