-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Add env var for configurable base or root directory #748
Copy link
Copy link
Closed
Description
Problem
Currently, all T3 Code data is hardcoded to ~/.t3 with no way to configure a different base location:
| Path | Override? |
|---|---|
~/.t3/userdata/ (state) |
Yes T3CODE_STATE_DIR |
~/.t3/dev/ (dev state) |
Yes --state-dir |
~/.t3/worktrees/ |
No (hardcoded) |
Users who want to store T3 Code data in a different location (e.g., ~/.config/t3, encrypted volumes, network drives, or XDG-compliant paths) currently have no single config to control this.
Proposal
Add a T3CODE_BASE_DIR environment variable that serves as the root for all T3 Code paths:
T3CODE_BASE_DIR (default: ~/.t3)
├── userdata/ ← state (T3CODE_STATE_DIR takes precedence)
├── dev/ ← dev state
└── worktrees/ ← git worktrees
Behavior
- Default:
~/.t3(no breaking change) - Override:
T3CODE_BASE_DIR=~/.config/t3moves everything - Backwards compat:
T3CODE_STATE_DIRstill takes precedence for state directory - CLI flag:
--base-dirfor dev-runner and server
Happy to implement if approved :)
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels