Skip to content

Conversation

@ammar-agent
Copy link
Collaborator

@ammar-agent ammar-agent commented Nov 13, 2025

Renames CMUX_TEST_ROOT to CMUX_ROOT for clearer intent. This environment variable overrides the default cmux data directory and is useful beyond just testing scenarios (e.g., when developers want to run with a clean slate or isolate different development environments).

Changes

  • CMUX_TEST_ROOTCMUX_ROOT in all references (paths.ts, main-desktop.ts, electronTest.ts)
  • Updated comments to match the new name

Behavior

No behavior changes - this is purely a rename:

The rename clarifies that this variable isn't just for tests - developers can use it anytime they want explicit control over the data directory.

Generated with cmux

Renames CMUX_TEST_ROOT to CMUX_ROOT for clearer intent - this env var is
not just for tests, but for any scenario where you want to override the
default data directory.

The -dev suffix behavior from #573 is preserved:
- `make start` uses `~/.cmux-dev` (NODE_ENV=development)
- Packaged apps use `~/.cmux`
- `CMUX_ROOT=/custom/path` overrides both

Changes:
- Renamed CMUX_TEST_ROOT → CMUX_ROOT in all files
- Updated comments to reflect the clearer naming
- All existing behavior preserved

_Generated with `cmux`_
@ammar-agent ammar-agent changed the title 🤖 refactor: rename CMUX_TEST_ROOT to CMUX_ROOT, remove mandatory -dev suffix 🤖 refactor: rename CMUX_TEST_ROOT to CMUX_ROOT Nov 13, 2025
Copy link

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".

return process.env.CMUX_ROOT;
}

const baseName = ".cmux";

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Removing -dev suffix is incomplete

The change description says make start should now use ~/.cmux by default, but getCmuxHome() still appends a "-dev" suffix whenever NODE_ENV === "development". The start make target continues to set NODE_ENV=development, so after this commit the default runtime path is still ~/.cmux-dev unless callers manually set CMUX_ROOT. This keeps the old behavior and defeats the goal of switching to the production data directory by default. To actually restore ~/.cmux, either remove the suffix logic here or stop forcing NODE_ENV=development when starting the app.

Useful? React with 👍 / 👎.

@ammar-agent
Copy link
Collaborator Author

Updated PR description to clarify this is a pure rename with no behavior changes. The -dev suffix behavior from #573 is intentionally preserved.

@ammario ammario merged commit c91560e into main Nov 13, 2025
14 checks passed
@ammario ammario deleted the fix-root branch November 13, 2025 16:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants