Fix gt sling code review issues (gt-z9qoo)
- Fix hook location for remote targets using tmux.GetPaneWorkDir() - Add --var/--on conflict error check - Add warning for JSON parse fallback (not yet fatal) - Capture stderr for wisp command - Remove dead code: detectAgentIdentity(), detectAgentIdentityForHook(), detectCloneRootForHook() - Extract resolveSelfTarget() helper to reduce role-switching duplication 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -494,18 +494,12 @@ func hookBeadForHandoff(beadID string) error {
|
||||
return fmt.Errorf("bead '%s' not found", beadID)
|
||||
}
|
||||
|
||||
// Determine agent identity
|
||||
agentID, err := detectAgentIdentity()
|
||||
// Determine agent identity and clone root
|
||||
agentID, _, cloneRoot, err := resolveSelfTarget()
|
||||
if err != nil {
|
||||
return fmt.Errorf("detecting agent identity: %w", err)
|
||||
}
|
||||
|
||||
// Get clone root for wisp storage
|
||||
cloneRoot, err := detectCloneRoot()
|
||||
if err != nil {
|
||||
return fmt.Errorf("detecting clone root: %w", err)
|
||||
}
|
||||
|
||||
// Create the slung work wisp
|
||||
sw := wisp.NewSlungWork(beadID, agentID)
|
||||
sw.Subject = handoffSubject
|
||||
|
||||
Reference in New Issue
Block a user