Skip to content

nREPL middleware that prints "eval"-ed forms on server stdout

Notifications You must be signed in to change notification settings

pinealan/niddle

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

45 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

niddle

niddle is a nREPL middleware that prints eval-ed forms and their corresponding results onto stdout of the nREPL server process. One use-case for this middleware is when the nREPL server is started non-interactively on the cli, but you'd like to keep track of all that has been eval-ed on the same CLI. (think Cursive REPL)

demo video

Colored pretty printing is done with puget.

Usage

{...
 :aliases
 {:niddle {:extra-deps {org.clojure/clojure {:mvn/version "1.10.1"}
                        niddle {:git/url "https://github.com/pinealan/niddle.git" }}
           :main-opts ["-m" "nrepl.cmdline" "--middleware" "[niddle.print/niddle-mw]"]}

Motivation

I really like the idea of having single REPL view that keeps track of all eval-ed forms and values, no matter where they came from. This supports a workflow where forms maybe sent from either CLI nREPL client, an editor, or even a running process.

I've tried looking for tooling that gives this experience on vim+tmux setup, but neither vim-fireplace nor vim-iced seem to provide that. In fact since the goal is to show all eval-ed forms from any client, the intercept point must be on the server-side, hence a nREPL middleware.

About

nREPL middleware that prints "eval"-ed forms on server stdout

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages