mirror of
https://github.com/getpaseo/paseo.git
synced 2026-11-06 16:34:36 +00:00
fix(server): give agents their workspace id as PASEO_WORKSPACE_ID
Agents got PASEO_AGENT_ID and PASEO_AGENT_CWD but not their workspace id, so an agent couldn't rename or archive its own workspace, or name it to create_agent, when several workspaces share its cwd. The launch env now sets PASEO_WORKSPACE_ID whenever the agent has a workspace, including on resume after a daemon restart, where the id now comes from the stored record. OpenCode treats it as a per-session key, so it doesn't force a dedicated server. Refs #5098 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
committed by
paseo-bot[bot]
co-authored by
Claude Opus 5.5
parent
471db4bdb5
commit
005ffbffd5
@@ -211,6 +211,8 @@ paseo workspace rename <workspace-id> --reset # back to the branch or director
|
||||
paseo workspace archive <workspace-id>
|
||||
```
|
||||
|
||||
Inside an agent session, `PASEO_WORKSPACE_ID` holds the agent's own workspace ID, so an agent can run `paseo workspace rename "$PASEO_WORKSPACE_ID" "Auth rework"` or `paseo workspace archive "$PASEO_WORKSPACE_ID"` even when other workspaces share its directory.
|
||||
|
||||
Add `--forge <name>` to PR checkout when Paseo cannot infer the forge from the source checkout. See [Git worktrees](/docs/worktrees) for setup hooks and services.
|
||||
|
||||
## Terminals
|
||||
|
||||
@@ -202,6 +202,8 @@ paseo workspace rename <workspace-id> --reset # back to the branch or director
|
||||
paseo workspace archive <workspace-id>
|
||||
```
|
||||
|
||||
在 Agent 会话中,`PASEO_WORKSPACE_ID` 保存该 Agent 自己的工作区 ID。即使其他工作区共享同一个目录,Agent 也可以运行 `paseo workspace rename "$PASEO_WORKSPACE_ID" "Auth rework"` 或 `paseo workspace archive "$PASEO_WORKSPACE_ID"`。
|
||||
|
||||
当 Paseo 无法从源检出推断代码托管平台时,为 PR 检出添加 `--forge <name>`。setup 钩子和服务见 [Git worktree](/docs/worktrees)。
|
||||
|
||||
## 终端 {#terminals}
|
||||
|
||||
@@ -598,7 +598,7 @@ Creation request
|
||||
→ resolve defaults and validate provider configuration
|
||||
→ derive launch configuration with Paseo runtime tools and daemon prompt
|
||||
→ agent.open.before hooks (same ordering; env and plugin-local tools and MCP servers)
|
||||
→ set PASEO_AGENT_ID and PASEO_AGENT_CWD
|
||||
→ set PASEO_AGENT_ID, PASEO_AGENT_CWD, and PASEO_WORKSPACE_ID when the agent has a workspace
|
||||
→ open provider session and save agent configuration
|
||||
```
|
||||
|
||||
|
||||
@@ -581,7 +581,7 @@ Creation request
|
||||
→ resolve defaults and validate provider configuration
|
||||
→ derive launch configuration with Paseo runtime tools and daemon prompt
|
||||
→ agent.open.before hooks (same ordering; env and plugin-local tools and MCP servers)
|
||||
→ set PASEO_AGENT_ID and PASEO_AGENT_CWD
|
||||
→ set PASEO_AGENT_ID, PASEO_AGENT_CWD, and PASEO_WORKSPACE_ID when the agent has a workspace
|
||||
→ open provider session and save agent configuration
|
||||
```
|
||||
|
||||
|
||||
Reference in New Issue
Block a user