diff --git a/CHANGELOG.md b/CHANGELOG.md index 693c55a33..98ee02e4c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -100,6 +100,7 @@ - Gateway/CLI: add `clawdbot gateway --dev/--reset` to auto-create a dev config/workspace with a robot identity (no BOOTSTRAP.md), and reset wipes config/creds/sessions/workspace (subcommand --dev no longer collides with global --dev profile). — thanks @steipete - Configure: stop prompting to open the Control UI (still shown in onboarding). — thanks @steipete - Telegram: suppress grammY getUpdates stack traces; log concise retry message instead. — thanks @steipete +- Gateway/CLI: allow dev profile (`clawdbot --dev`) to auto-create the dev config + workspace. — thanks @steipete - Config: fix Minimax hosted onboarding to write `agents.defaults` and allow `msteams` as a heartbeat target. — thanks @steipete ## 2026.1.8 diff --git a/src/cli/gateway-cli.ts b/src/cli/gateway-cli.ts index f478b3293..eda414809 100644 --- a/src/cli/gateway-cli.ts +++ b/src/cli/gateway-cli.ts @@ -146,6 +146,8 @@ const resolveDevWorkspaceDir = ( env: NodeJS.ProcessEnv = process.env, ): string => { const baseDir = resolveDefaultAgentWorkspaceDir(env, os.homedir); + const profile = env.CLAWDBOT_PROFILE?.trim().toLowerCase(); + if (profile === "dev") return baseDir; return `${baseDir}-${DEV_AGENT_WORKSPACE_SUFFIX}`; }; @@ -536,7 +538,10 @@ async function runGatewayCommand( opts: GatewayRunOpts, params: GatewayRunParams = {}, ) { - if (opts.reset && !opts.dev) { + const isDevProfile = process.env.CLAWDBOT_PROFILE?.trim().toLowerCase() === + "dev"; + const devMode = Boolean(opts.dev) || isDevProfile; + if (opts.reset && !devMode) { defaultRuntime.error("Use --reset with --dev."); defaultRuntime.exit(1); return; @@ -577,7 +582,7 @@ async function runGatewayCommand( process.env.CLAWDBOT_RAW_STREAM_PATH = rawStreamPath; } - if (opts.dev) { + if (devMode) { await ensureDevGatewayConfig({ reset: Boolean(opts.reset) }); }