@@ -243,22 +243,46 @@ configurable.
243243You can see all the configuration options available using the command
244244` M-x customize-group RET inf-clojure ` .
245245
246+ The supported repl-features are in an alist called
247+ ` inc-clojure-repl-features ` and it has the following shape:
248+
249+ ``` emacs-lisp
250+ '((cljs . ((doc . "(cljs.repl/doc %s)")
251+ (source . "(cljs.repl/source %s)")
252+ (arglists . "(try (->> '%s cljs.core/resolve cljs.core/meta :arglists) (catch :default _ nil))")
253+ (apropos . "(cljs.repl/apropos \"%s\")")
254+ (ns-vars . "(cljs.repl/dir %s)")
255+ (set-ns . "(in-ns '%s)")
256+ (macroexpand . "(cljs.core/macroexpand '%s)")
257+ (macroexpand-1 . "(cljs.core/macroexpand-1 '%s)"))))
258+ ```
259+
260+ If you want to add a new repl type, just `(add-to-list
261+ 'inf-clojure-repl-features (cons new-repl-type '((doc
262+ . "(myrepl/doc-command %s") ...)))`
263+
264+ If you want to update a specific form there is a function
265+ ` inf-clojure-update-repl-feature ` which can be used like so:
266+
267+ ``` emacs-lisp
268+ (inf-clojure-update-feature 'clojure 'completion "(complete.core/completions \"%s\")")
269+ ```
270+
246271#### REPL Type
247272
248- An ` inf-clojure ` REPL can be of different types: Clojure, ClojureScript, Lumo
249- and Planck are all potentially valid options.
273+ An ` inf-clojure ` REPL can be of different types: Clojure,
274+ ClojureScript, Lumo and Planck are all potentially valid options.
250275
251- At the moment, the default Clojure REPL, the Lumo REPL, the Planck REPL and the
252- Joker REPL are supported (standard ClojureScript is lacking mostly because some
253- features require to access the compiler state,
254- [ cljs-tooling] ( https://github.com/clojure-emacs/cljs-tooling ) is a good
255- candidate for enabling support).
276+ At the moment, the default Clojure REPL, the Lumo REPL, the Planck
277+ REPL and the Joker REPL are supported.
256278
257- What does it mean that a REPL type is supported - well it means that ` inf-clojure `
258- would use the proper code internally to power commands like definition lookup and friends.
259- Those differ from REPL to REPL and can't be implemented in a REPL-independent way. At
260- boot type ` inf-clojure ` tries to detect the type of the REPL that was started and uses
261- this type to dispatch the proper code for the respective REPL type.
279+ What does it mean that a REPL type is supported - well it means that
280+ ` inf-clojure ` would use the proper code internally to power commands
281+ like definition lookup and friends. Those differ from REPL to REPL
282+ and can't be implemented in a REPL-independent way. At startup
283+ ` inf-clojure ` tries to detect the type of the REPL that was started
284+ and uses this type to dispatch the proper code for the respective REPL
285+ type.
262286
263287By default ` inf-clojure ` would start a standard Clojure REPL using
264288` lein ` or ` boot ` but you can easily change this. To boot some other REPL just use the
0 commit comments