mirror of
https://github.com/anthropics/claude-code.git
synced 2026-02-19 04:27:33 -08:00
Compare commits
1 Commits
8c09097e8c
...
claude/sla
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
f799a47740 |
@@ -230,8 +230,8 @@ Read from hooks to coordinate agents:
|
|||||||
AGENT_NAME=$(echo "$FRONTMATTER" | grep '^agent_name:' | sed 's/agent_name: *//')
|
AGENT_NAME=$(echo "$FRONTMATTER" | grep '^agent_name:' | sed 's/agent_name: *//')
|
||||||
COORDINATOR=$(echo "$FRONTMATTER" | grep '^coordinator_session:' | sed 's/coordinator_session: *//')
|
COORDINATOR=$(echo "$FRONTMATTER" | grep '^coordinator_session:' | sed 's/coordinator_session: *//')
|
||||||
|
|
||||||
# Send notification to coordinator
|
# Send notification to coordinator (use -L default to ensure correct socket)
|
||||||
tmux send-keys -t "$COORDINATOR" "Agent $AGENT_NAME completed task" Enter
|
tmux -L default send-keys -t "$COORDINATOR" "Agent $AGENT_NAME completed task" Enter
|
||||||
```
|
```
|
||||||
|
|
||||||
### Pattern 3: Configuration-Driven Behavior
|
### Pattern 3: Configuration-Driven Behavior
|
||||||
|
|||||||
@@ -76,10 +76,10 @@ fi
|
|||||||
# Send notification to coordinator
|
# Send notification to coordinator
|
||||||
NOTIFICATION="🤖 Agent ${AGENT_NAME} (Task ${TASK_NUMBER}, PR #${PR_NUMBER}) is idle."
|
NOTIFICATION="🤖 Agent ${AGENT_NAME} (Task ${TASK_NUMBER}, PR #${PR_NUMBER}) is idle."
|
||||||
|
|
||||||
if tmux has-session -t "$COORDINATOR_SESSION" 2>/dev/null; then
|
if tmux -L default has-session -t "$COORDINATOR_SESSION" 2>/dev/null; then
|
||||||
tmux send-keys -t "$COORDINATOR_SESSION" "$NOTIFICATION" Enter
|
tmux -L default send-keys -t "$COORDINATOR_SESSION" "$NOTIFICATION" Enter
|
||||||
sleep 0.5
|
sleep 0.5
|
||||||
tmux send-keys -t "$COORDINATOR_SESSION" Enter
|
tmux -L default send-keys -t "$COORDINATOR_SESSION" Enter
|
||||||
fi
|
fi
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
|
|||||||
Reference in New Issue
Block a user