Skip to content

Commit

Permalink
fix(prepare): respect --dotenv (#377)
Browse files Browse the repository at this point in the history
  • Loading branch information
DamianGlowala committed Mar 28, 2024
1 parent af178b2 commit 7e0fba6
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/commands/prepare.ts
Expand Up @@ -15,6 +15,10 @@ export default defineCommand({
description: 'Prepare Nuxt for development/build',
},
args: {
dotenv: {
type: 'string',
description: 'Path to .env file',
},
...sharedArgs,
...legacyRootDirArgs,
},
Expand All @@ -30,6 +34,10 @@ export default defineCommand({
} = await loadKit(cwd)
const nuxt = await loadNuxt({
cwd,
dotenv: {
cwd,
fileName: ctx.args.dotenv,
},
overrides: {
_prepare: true,
logLevel: ctx.args.logLevel as 'silent' | 'info' | 'verbose',
Expand Down

0 comments on commit 7e0fba6

Please sign in to comment.