fix: ops dashboard 5-pane layout with 3 equal feed panes

Status(40%) + Controls on left, Kimi/Claude/Gemini feeds(60%) stacked right.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
Alexander Whitestone
2026-03-22 19:07:27 -04:00
parent 4f83465430
commit 0dba33c811

View File

@@ -1,66 +1,73 @@
#!/usr/bin/env bash #!/usr/bin/env bash
# ── Hermes Ops Dashboard v2 ──────────────────────────────────────────── # ── Hermes Ops Dashboard v2 ────────────────────────────────────────────
# 5-pane layout with triple agent feeds: # 5-pane layout:
# ┌───────────────────────────────────┬────────────────────────────────┐ # ┌───────────────────────────────────────────────┐
# │ │ KIMI LIVE FEED # │ │ KIMI LIVE FEED │
# │ STATUS + GITEA + QUEUE ├────────────────────────────────┤ # │ STATUS PANEL ├─────────────────────────────┤
# │ (auto-refresh 20s) │ CLAUDE LIVE FEED # │ (auto-refresh) │ CLAUDE LIVE FEED │
# │ ├────────────────────────────────┤ # │ ─────────────────────────────┤
# │ │ GEMINI LIVE FEED # │ │ GEMINI LIVE FEED │
# ├───────────────────────────────────┴────────────────────────────────┤ # ├──────────────────┘ │
# │ CONTROLS (bash prompt with helpers loaded) # │ CONTROLS
# └──────────────────────────────────────────────────────────────────── # └─────────────────────────────────────────────────┘
# ─────────────────────────────────────────────────────────────────────── # ───────────────────────────────────────────────────────────────────────
SESSION="ops" SESSION="ops"
tmux kill-session -t "$SESSION" 2>/dev/null tmux kill-session -t "$SESSION" 2>/dev/null
sleep 1
tmux new-session -d -s "$SESSION" # Initialize log files
# Split: left status (55%) | right feeds (45%)
tmux split-window -h -p 45 -t "$SESSION"
# Split left pane: top status (80%) | bottom controls (20%)
tmux split-window -v -p 20 -t "$SESSION:1.1"
# Split right pane into 3 equal feeds: kimi (top 33%) | claude (mid 33%) | gemini (bot 33%)
tmux split-window -v -p 67 -t "$SESSION:1.2"
tmux split-window -v -p 50 -t "$SESSION:1.3"
# Initialize log files if they don't exist
touch ~/.hermes/logs/kimi-loop.log 2>/dev/null touch ~/.hermes/logs/kimi-loop.log 2>/dev/null
touch ~/.hermes/logs/claude-loop.log 2>/dev/null touch ~/.hermes/logs/claude-loop.log 2>/dev/null
touch ~/.hermes/logs/gemini-loop.log 2>/dev/null touch ~/.hermes/logs/gemini-loop.log 2>/dev/null
# Pane 1 (top-left): consolidated status, auto-refresh # Create session
tmux new-session -d -s "$SESSION"
# Horizontal split: left 40% (status) | right 60% (feeds)
tmux split-window -h -p 60 -t "$SESSION"
# Split right pane into 3 equal feeds
tmux split-window -v -p 67 -t "$SESSION:1.2"
tmux split-window -v -p 50 -t "$SESSION:1.3"
# Right is now: 1.2=kimi, 1.3=claude, 1.4=gemini
# Split left pane: status top (85%) | controls bottom (15%)
tmux split-window -v -p 15 -t "$SESSION:1.1"
# Left is now: 1.1=status, 1.2=controls
# (inserts shift right panes to 1.3=kimi, 1.4=claude, 1.5=gemini)
# === Fill panes ===
# Status panel
tmux send-keys -t "$SESSION:1.1" "watch -n 20 -t -c 'bash ~/.hermes/bin/ops-panel.sh'" Enter tmux send-keys -t "$SESSION:1.1" "watch -n 20 -t -c 'bash ~/.hermes/bin/ops-panel.sh'" Enter
# Pane 2 (top-right): kimi live feed with color # Controls
tmux send-keys -t "$SESSION:1.2" "echo -e '\\033[1m\\033[33m KIMI FEED\\033[0m' && tail -f ~/.hermes/logs/kimi-loop.log | GREP_COLOR='1;32' grep --color=always -E 'SUCCESS|$' | GREP_COLOR='1;31' grep --color=always -E 'FAILED|BACKOFF|$' | GREP_COLOR='1;36' grep --color=always -E 'ISSUE #[0-9]+|$'" Enter tmux send-keys -t "$SESSION:1.2" "source ~/.hermes/bin/ops-helpers.sh && ops-help" Enter
# Pane 3 (mid-right): claude live feed with color # Kimi feed
tmux send-keys -t "$SESSION:1.3" "echo -e '\\033[1m\\033[35m CLAUDE FEED\\033[0m' && tail -f ~/.hermes/logs/claude-loop.log | GREP_COLOR='1;32' grep --color=always -E 'SUCCESS|$' | GREP_COLOR='1;31' grep --color=always -E 'FAILED|BACKOFF|$' | GREP_COLOR='1;36' grep --color=always -E 'ISSUE #[0-9]+|$'" Enter tmux send-keys -t "$SESSION:1.3" "echo -e '\\033[1m\\033[33m KIMI FEED\\033[0m' && tail -f ~/.hermes/logs/kimi-loop.log | GREP_COLOR='1;32' grep --color=always -E 'SUCCESS|$' | GREP_COLOR='1;31' grep --color=always -E 'FAILED|BACKOFF|$' | GREP_COLOR='1;36' grep --color=always -E 'ISSUE #[0-9]+|$'" Enter
# Pane 4 (bottom-right): gemini live feed with color # Claude feed
tmux send-keys -t "$SESSION:1.4" "echo -e '\\033[1m\\033[32m GEMINI FEED\\033[0m' && tail -f ~/.hermes/logs/gemini-loop.log | GREP_COLOR='1;32' grep --color=always -E 'SUCCESS|$' | GREP_COLOR='1;31' grep --color=always -E 'FAILED|BACKOFF|$' | GREP_COLOR='1;36' grep --color=always -E 'ISSUE #[0-9]+|$'" Enter tmux send-keys -t "$SESSION:1.4" "echo -e '\\033[1m\\033[35m CLAUDE FEED\\033[0m' && tail -f ~/.hermes/logs/claude-loop.log | GREP_COLOR='1;32' grep --color=always -E 'SUCCESS|$' | GREP_COLOR='1;31' grep --color=always -E 'FAILED|BACKOFF|$' | GREP_COLOR='1;36' grep --color=always -E 'ISSUE #[0-9]+|$'" Enter
# Pane 5 (bottom-left): controls with helpers sourced # Gemini feed
tmux send-keys -t "$SESSION:1.5" "source ~/.hermes/bin/ops-helpers.sh && ops-help" Enter tmux send-keys -t "$SESSION:1.5" "echo -e '\\033[1m\\033[32m GEMINI FEED\\033[0m' && tail -f ~/.hermes/logs/gemini-loop.log | GREP_COLOR='1;32' grep --color=always -E 'SUCCESS|$' | GREP_COLOR='1;31' grep --color=always -E 'FAILED|BACKOFF|$' | GREP_COLOR='1;36' grep --color=always -E 'ISSUE #[0-9]+|$'" Enter
# Set pane titles # Pane titles
tmux select-pane -t "$SESSION:1.1" -T "Status" tmux select-pane -t "$SESSION:1.1" -T "Status"
tmux select-pane -t "$SESSION:1.2" -T "Kimi Feed" tmux select-pane -t "$SESSION:1.2" -T "Controls"
tmux select-pane -t "$SESSION:1.3" -T "Claude Feed" tmux select-pane -t "$SESSION:1.3" -T "Kimi Feed"
tmux select-pane -t "$SESSION:1.4" -T "Gemini Feed" tmux select-pane -t "$SESSION:1.4" -T "Claude Feed"
tmux select-pane -t "$SESSION:1.5" -T "Controls" tmux select-pane -t "$SESSION:1.5" -T "Gemini Feed"
# Border styling # Styling
tmux set-option -t "$SESSION" pane-border-status top tmux set-option -t "$SESSION" pane-border-status top
tmux set-option -t "$SESSION" pane-border-format " #{pane_title} " tmux set-option -t "$SESSION" pane-border-format " #{pane_title} "
tmux set-option -t "$SESSION" pane-border-style "fg=colour240" tmux set-option -t "$SESSION" pane-border-style "fg=colour240"
tmux set-option -t "$SESSION" pane-active-border-style "fg=cyan" tmux set-option -t "$SESSION" pane-active-border-style "fg=cyan"
# Focus on controls pane # Focus on controls
tmux select-pane -t "$SESSION:1.5" tmux select-pane -t "$SESSION:1.2"
tmux attach -t "$SESSION" echo "Dashboard ready — attach with: tmux attach -t ops"