Create
Creating a workspace copies project templates into workspace settings, runs the setup script, and reserves ports based on port definitions.
- • Git projects create a worktree directory for the workspace.
- • Branch creation uses this precedence: local branch, then remote branch, then new branch from target.
- • A branch is required for Git workspaces.
Stop and Restart
Restart runs stop first, then launch, for the same workspace.
- • Processes are gracefully interrupted, then terminated if needed.
- • The stop script runs after process termination (if configured).
- • Tracked workspace windows are closed (terminals and browsers).
Use mx workspace up for idempotent automation: it launches stopped workspaces and otherwise does nothing by default. Add --restart to force stop then launch when runtime state is already present.