UNPKG

nuxi

Version:
36 lines (35 loc) 1.17 kB
import { t as defineCommand } from "./dist-B03QHgrC.mjs"; import { o as v } from "./dist-BkNIIgFa.mjs"; import { a as legacyRootDirArgs, n as dotEnvArgs, o as logLevelArgs, r as envNameArgs, t as cwdArgs } from "./_shared-D6pJgr6t.mjs"; import { c as resolve } from "./pathe.M-eThtNZ-BfnU2wdd.mjs"; import process from "node:process"; //#region src/commands/dev-child.ts var dev_child_default = defineCommand({ meta: { name: "_dev", description: "Run Nuxt development server (internal command to start child process)" }, args: { ...cwdArgs, ...logLevelArgs, ...envNameArgs, ...dotEnvArgs, ...legacyRootDirArgs, clear: { type: "boolean", description: "Clear console on restart", negativeDescription: "Disable clear console on restart" } }, async run(ctx) { if (!process.send && !v) console.warn("`nuxi _dev` is an internal command and should not be used directly. Please use `nuxi dev` instead."); const cwd = resolve(ctx.args.cwd || ctx.args.rootDir); const { initialize } = await import("./dev/index.mjs"); await initialize({ cwd, args: ctx.args }, ctx); } }); //#endregion export { dev_child_default as default };