CLI tool to capture output from Claude agents running in tmux windows.
Part of the gastown ecosystem. Claude detection logic adapted from gastown.
Go:
go install github.com/nmelo/gaspeek@latest
mv $(go env GOPATH)/bin/gaspeek $(go env GOPATH)/bin/gpFrom inside tmux, capture recent output from a window:
gp editorCapture from all windows in the current session:
gp --allOnly capture from windows running Claude:
gp --all --detectLimit the number of lines captured:
gp -n 50 editorTarget a different session:
gp -s work --all-n, --lines INT Number of lines to capture (default: 100)
-s, --session NAME Target session (default: current)
-a, --all Capture from all windows
-d, --detect Only capture from windows running Claude
Uses tmux capture-pane to grab the scrollback buffer from target windows. Output includes a header showing window name and session for each captured pane.
Claude detection checks pane_current_command for node, claude, or version patterns, plus child process inspection when the pane shows a shell.