Settings

Theme

Show HN: Interactive bash session for coding agents

github.com

2 points by renonce 4 months ago · 1 comment · 1 min read

Reader

In Claude Code, the bash tool allows for a single round of interaction only - supply command, run and get the output. Even when running in the background, the tools only allow fetching outputs from bash periodically, and does not support interacting with it or providing inputs. This prevents models from using certain programs such as gdb and Python REPL.

I've written a very simple script in ~30 lines that allows Claude Code to spawn bash and interact with it. User can attach to the terminal and type into it as Claude Code is working simultaneously. It additionally logs terminal history which can be replayed with `scriptreplay`.

See it use vim and gdb in real action (somewhat lame): `asciinema play https://github.com/vincent-163/bgbash/raw/refs/heads/asciine...`

This is a minimum working sample with lots of rough edges. Looking forward to extensions of this idea!

mutant 4 months ago

huh, i did something like this using tmux, and shared sessions, i love seeing the full interactions

Keyboard Shortcuts

j
Next item
k
Previous item
o / Enter
Open selected item
?
Show this help
Esc
Close modal / clear selection