feat(workspace): make workspace location configurable via env var
- Add MYCLAUDE_WORKSPACE_ROOT env var, default ~/workspace - Auto-create workspace directory if it does not exist - Move workspace/CLAUDE.md + .gitignore to workspace_template/ - Remove hardcoded symlink paths from workspace template - Update get_workspace_root() with env-var priority logic - Update metabot bots.json defaultWorkingDirectory to ~/workspace
This commit is contained in:
@@ -42,16 +42,22 @@
|
||||
|
||||
```
|
||||
myclaude/
|
||||
├── myclaude/ # Python 源码
|
||||
│ ├── cli.py # CLI entrypoint
|
||||
│ ├── commands/ # 子命令
|
||||
├── myclaude/ # Python 源码
|
||||
│ ├── cli.py # CLI entrypoint
|
||||
│ ├── commands/ # 子命令
|
||||
│ └── ...
|
||||
├── workspace/ # 主工作环境 (默认 --cwd 目标)
|
||||
│ └── CLAUDE.md # 日常工作指令
|
||||
└── .claude/ # Claude Code 运行时配置
|
||||
├── workspace_template/ # workspace 模板 (CLAUDE.md, .gitignore)
|
||||
└── .claude/ # Claude Code 运行时配置
|
||||
|
||||
workspace/ # 主工作环境 (默认 --cwd 目标, 独立目录)
|
||||
├── CLAUDE.md # 日常工作指令
|
||||
├── myacademia -> ... # 符号链接
|
||||
├── myslides -> ...
|
||||
└── tmp/ # 临时文件
|
||||
```
|
||||
|
||||
默认运行 `myclaude`(不带 --cwd)时,cwd 为 `workspace/`,指向工作区 CLAUDE.md。
|
||||
默认运行 `myclaude`(不带 --cwd)时,cwd 为 `MYCLAUDE_WORKSPACE_ROOT`
|
||||
(默认 `~/workspace`),指向独立工作区 CLAUDE.md。
|
||||
开发 CLI 时运行 `myclaude --cwd .` 以读取本文件。
|
||||
|
||||
---
|
||||
|
||||
Reference in New Issue
Block a user