()
| 149 | } |
| 150 | |
| 151 | function getWorkspaceRoot() { |
| 152 | if (process.env.OPENCLAW_WORKSPACE) { |
| 153 | return process.env.OPENCLAW_WORKSPACE; |
| 154 | } |
| 155 | |
| 156 | const repoRoot = getRepoRoot(); |
| 157 | const workspaceDir = path.join(repoRoot, 'workspace'); |
| 158 | if (fs.existsSync(workspaceDir)) { |
| 159 | return workspaceDir; |
| 160 | } |
| 161 | |
| 162 | return repoRoot; |
| 163 | } |
| 164 | |
| 165 | function getLogsDir() { |
| 166 | return process.env.EVOLVER_LOGS_DIR || path.join(getWorkspaceRoot(), 'logs'); |
no test coverage detected