What is it?
Paravim is an editor for Clojure that...
- Runs inside your project as a library, not as a separate application like traditional editors
- Uses a real copy of Vim, not some kind of emulation
- Renders its UI with OpenGL, not with a forked web browser
By running inside your project, it has complete access to the running state of your program. The ambition is to create something that follows the Lisp and Smalltalk tradition, blurring the line between your tools and your code to provide unprecedented interactivity.
Join the discussion on /r/Paravim and read the source code.
How do I get started?
The easiest way to run it is with the Clojure CLI tool. On Windows or Linux, run this in any directory you want:
clojure -Sdeps "{:deps {paravim {:mvn/version \""RELEASE\""}}}" -m paravim.start
On Mac OS, you need to add a special flag:
clojure -Sdeps "{:deps {paravim {:mvn/version \""RELEASE\""}}}" -J-XstartOnFirstThread -m paravim.start
For Leiningen users, see this sample project.clj.
NOTE: On Linux, there have been some UnsatisfiedLinkError
s due to libtinfo.so.5
not being present. If you have apt, try apt install libtinfo5
. If you use Arch btw, see this issue for a solution.
Embedding inside a game
Since Paravim is rendered with OpenGL, it can be embedded in a game:
In this example, it is being rendered on top of a platformer and toggled with the escape key. You can try it yourself by cloning the example repo and running clj -A:dev native
in any of the projects (on Mac OS you'll need to do clj -A:dev:macos native
) .
How does this compare to Nightlight?
Nightlight was my first attempt at the idea of an editor as a library. It spins up a local web server that provides a simple UI to edit code. While it validated the idea, its custom web-based editor just doesn't compare to powerful and timeless editors like Vim. With Paravim I'm trying a re-do of the idea without compromises.