I have Ctrl+` set to switch focus between the editor and the terminal panes in VSCode, so I can toggle between them pretty easily as this is also my workflow
It’s a nice short cut if you have a keyboard with backtick to the left of 1 in the numeral row. If you’re from a country where keyboards have a different key there, I would recommend setting up a short cut manually.
As the author describes though, I found myself copy-pasting a lot between LLM chat and editing buffers. In tmux, I have a really simple function that copies select panes (using tmux capture-pane) into my prompt, or I can give it full files for context. Most of the time though, I can do something like `llm -t 0 -t 1 'what is this libSSL error indicating? here's my code', where -t 0 gives it my vim pane and -t 1 gives it the terminal I'm running things in. I've been surprised that this somewhat rudimentary approach has felt far more effective than the more sophisticated editors I've been trying.
Is this just me? Does it seem to others that the LLM-enabled editors coming out these days still require a lot of copy-pasting of context that can be easily provided with just a dump of tmux output?
Everything-is-just-text might be crude but dang does it make quick and dirty LLM integrations a snap!
I know people who use ^Z to suspend vim and then foreground it again.
You don't mind losing all your editor state? If you don't like working with multiple terminal windows, why not open a term within vim with `:term`?
I run a pretty light vanilla vimrc (60 lines maybe) and with two lines you can enable vim undofiles and returning the cursor to the last location upom reopening a file. For me, quitting vim is functionally equivalent to ^Z?
Retaining positions, buffers, and edit history between sessions is all straightforward in vanilla vim though. Unless you run an autolinter or formatter that edits your target file and wipes the history.
I don't use any other LSPs which have a long warmup time, but if I did then they can also be used behind ra-multiplex.
In my configuration vim will save (among other things):
- Cursor position
- Undo history
- Register state
:term is clunky for me, mainly because my muscle memory is to just :wq
I got it working as seamlessly as I could once just in an attempt to use it but I stopped pretty quickly.
So it's fine for X11 terminals, but not for /dev/tty2
Don't forget you can just :!some-shell-command though - not just in vim but in lots of programs even.
Same! I run neovim in tmux together with stuff I hack on. I switch beteen tmux windows with shift-arrows and it works so well. I run this full screen in Ghostty. No distractions.
I try Zed and VSCode and I always come back to this setup. It works so well for me personally.