Maciej Janicki's website

tmux

2020-09-26 Executing code chunks from Vim

Recently “notebook” applications like Jupyter and RStudio have become a popular way of teaching and practicing programming. Their advantage is making programming interactive: you write several lines of code, then execute it and look what happens. You can tinker with your complex data structures and try unfamiliar functions out without the need to rerun the whole script each time. However, this also comes with the massive disadvantage: you are locked down to a GUI application and cannot edit the code with a decent text editor. In this tutorial, I show how to achieve the same effect using Vim, the standard REPL console, and tmux to connect them.

Tags: programming vim tmux