← Back to context

Comment by blueflow

1 day ago

> So it’s like Playwright/Puppeteer for the terminal

I mean, a tty is just a file descriptor... there have been script(1), expect(1) and chat(8) since the 80ies. tmux is not really necessary.

"tmux capture-pane" strips escape sequences that break the terminal and sets all the right variables; try using expect with e.g. neovim

These are all great. If you need to do something more involved, pexpect is also worth mentioning. It's a reimplementation of expect in python that's easy to be productive with quickly.

I used it in a previous job to automate configuring thousands of network devices