Skip to content

Commit

Permalink
feat(cli): add internal _generate and _build options (#5434)
Browse files Browse the repository at this point in the history
  • Loading branch information
pi0 authored Apr 1, 2019
1 parent 583e32a commit 516aea3
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion packages/cli/src/commands/build.js
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ export default {
}
},
async run(cmd) {
const config = await cmd.getNuxtConfig({ dev: false })
const config = await cmd.getNuxtConfig({ dev: false, _build: true })
const nuxt = await cmd.getNuxt(config)

if (cmd.argv.lock) {
Expand Down
2 changes: 1 addition & 1 deletion packages/cli/src/commands/dev.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ export default {
},

async _startDev(cmd, argv) {
const config = await cmd.getNuxtConfig({ dev: true })
const config = await cmd.getNuxtConfig({ dev: true, _build: true })
const nuxt = await cmd.getNuxt(config)

// Setup hooks
Expand Down
2 changes: 1 addition & 1 deletion packages/cli/src/commands/generate.js
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ export default {
}
},
async run(cmd) {
const config = await cmd.getNuxtConfig({ dev: false })
const config = await cmd.getNuxtConfig({ dev: false, _generate: true, _build: cmd.argv.build })

// Disable analyze if set by the nuxt config
if (!config.build) {
Expand Down

0 comments on commit 516aea3

Please sign in to comment.