inf-clojure

borkdude 2023-09-17T13:30:09.175999Z

What is the simplest way to test out inf-clojure with a custom stdin/stdout REPL?

borkdude 2023-09-17T13:32:59.868069Z

does inf-clojure only work with socket REPLs?

2023-09-17T15:24:11.943079Z

It works with stdio repls, that is my "daily driver" repl setup. If you have inf-clojure installed in emacs you should be able to just open some file in the project directory, then M-x inf-clojure, then select clojure as the repl type in the "startup command prompt" that comes up

2023-09-17T15:27:53.791179Z

if it's a custom type, instead of selecting clojure for the startup command, type your own command, and then pick one from the next list for the repl type (probably clojure is what you want there)

borkdude 2023-09-17T15:45:05.059729Z

It seems it forces me to choose one of the types, it doesn't allow me to type a custom command (cc @dpsutton)

borkdude 2023-09-17T15:45:45.096169Z

Also I can't type a space

borkdude 2023-09-17T15:47:27.725069Z

I can confirm that when I type "ffffff" it will say: can't find program fffff

borkdude 2023-09-17T15:47:43.371519Z

but how the heck do I type "node /Users/borkdude/dev/squint/node_cli.js repl"

borkdude 2023-09-17T15:49:11.552339Z

ah lol, copy paste worked

2023-09-17T15:49:30.990009Z

oh yeah if it's one word i think you can just press enter and ignore the [no match] and it will try to run that command. Not sure if there's an easy way around a command with a space build into the ui haha, nice!

borkdude 2023-09-17T15:50:35.376859Z

@jjttjj am I right that inf-clojure doesn't offer inline evaluation display of the result?

2023-09-17T15:52:57.001899Z

yup correct

borkdude 2023-09-17T15:53:23.374639Z

back to basics :)

2023-09-17T15:55:47.565889Z

I like to just have all my output in the repl window personally 🙂. It's not always ideal (like with print output being indistinguishable from eval results) but it gets the job done for me

☝️ 1
dpsutton 2023-09-17T16:00:35.600549Z

Might be our list display engine. Ivy versus others might make typing a form with no match easier depending on which lib you use

dpsutton 2023-09-17T16:06:18.664729Z

eval

(completing-read "check completing-read"
                 '("first choice" "second choice")
                 nil
                 'confirm-after-completion)
in your *scratch* buffer. I can easily type things with spaces in them

dpsutton 2023-09-17T16:06:46.101059Z

dpsutton 2023-09-17T16:07:29.496899Z

i think that will end up in (use-package ivy) which does the list selection an all that. been a while since i’ve set that up

dpsutton 2023-09-17T16:08:44.574329Z

> Ivy is an interactive interface for completion in Emacs. Emacs uses completion mechanism in a variety of contexts: code, menus, commands, variables, functions, etc. Completion entails listing, sorting, filtering, previewing, and applying actions on selected items. When active, ivy-mode completes the selection process by narrowing available choices while previewing in the minibuffer. Selecting the final candidate is either through simple keyboard character inputs or through powerful regular expressions. https://oremacs.com/swiper/ I guess it’s actually swiper. But the nomencalture gets weird because i think ivy and swiper are distributed in the same package

borkdude 2023-09-17T17:47:05.330399Z

Thanks folks

borkdude 2023-09-17T17:47:06.931609Z

https://github.com/squint-cljs/squint#repl