feat(agent): add Grok Build TUI adapter, runtime dispatch, and skill support
This commit is contained in:
@@ -104,7 +104,7 @@ detect_nearest_agent() {
|
||||
local base
|
||||
base="$(basename "$tok")"
|
||||
case "$base" in
|
||||
claude|agy|hermes|cline)
|
||||
claude|agy|hermes|cline|grok)
|
||||
match="$base"
|
||||
break
|
||||
;;
|
||||
@@ -128,6 +128,9 @@ detect_nearest_agent() {
|
||||
cline)
|
||||
detected_id=$(echo "$cmd_line" | grep -oE '(--id|--session-id)[[:space:]=]+[^[:space:]]+' | head -n 1 | sed -E 's/^(--id|--session-id)[[:space:]=]+//' || true)
|
||||
;;
|
||||
grok)
|
||||
detected_id=$(echo "$cmd_line" | grep -oE '(--session-id|--resume)[[:space:]=]+[^[:space:]]+' | head -n 1 | sed -E 's/^(--session-id|--resume)[[:space:]=]+//' || true)
|
||||
;;
|
||||
esac
|
||||
|
||||
if [ -n "$detected_id" ] && is_valid_id "$detected_id"; then
|
||||
@@ -142,6 +145,7 @@ detect_nearest_agent() {
|
||||
agy) env_var="${ANTIGRAVITY_CONVERSATION_ID:-}" ;;
|
||||
hermes) env_var="${HERMES_SESSION_ID:-}" ;;
|
||||
cline) env_var="${CLINE_SESSION_ID:-}" ;;
|
||||
grok) env_var="${GROK_SESSION_ID:-}" ;;
|
||||
esac
|
||||
|
||||
if [ -n "$env_var" ] && is_valid_id "$env_var"; then
|
||||
@@ -202,7 +206,7 @@ except Exception:
|
||||
target = sys.argv[1]
|
||||
for s in d.get("herdr_sessions", []):
|
||||
if s.get("status") == "running":
|
||||
for k in ["claude_session_id_own", "agy_conversation_id_own", "hermes_conversation_id_own", "cline_conversation_id_own"]:
|
||||
for k in ["claude_session_id_own", "agy_conversation_id_own", "hermes_conversation_id_own", "cline_conversation_id_own", "grok_session_id_own"]:
|
||||
if s.get(k) == target:
|
||||
sys.exit(1)
|
||||
sys.exit(0)
|
||||
|
||||
Reference in New Issue
Block a user