Fork me on GitHub
#emacs
<
2019-12-31
>
dazld12:12:51

I'm using parinfer, and really enjoying it - there's some behaviour i miss from the cursive implementation though

dazld12:12:49

for example..

(s/def ::foo {::baz 2
              ::bar 1})

dazld12:12:14

if i make ::foo shorter or longer, then in cursive the map and its indentation will move around too

dazld12:12:43

is this electric ?

dazld12:12:33

or.. if i realise (like now) that s/def is not what I wanted and actually it is s/explain then the rest of the expression including on the next lines would move around too

dazld12:12:38

something like this

dazld12:12:40

any ideas?

dazld13:12:29

that might be the trick

yuhan15:12:04

I use both aggressive-indent and adjust-parens, together they provide all the convenience of parinfer without the surprising behavior that can happen with giving up control of paren structure

didibus00:01:12

Hum, adjust-parens looks pretty great, I'll try it!

didibus00:01:28

Seems there is sp-indent-adjust-sexp on smartparens as well, not sure if it is as good

yuhan01:01:52

if I recall the difference is in fallback behaviour - adjust-parens only works at the beginning of lines and falls back to regular TAB completion otherwise

yuhan01:01:20

sp-indent-adjust-sexp does some unintuitive slurping/barfing when called in the middle of a line

didibus02:01:36

Cool, good to know thx

onetom16:12:48

@dazld parinfer has 2 modes, paren and indent mode. the demo animation on the parinfer mode site shows the behaviour you are talking about: https://github.com/DogLooksGood/parinfer-mode the parinfer layer docs (https://develop.spacemacs.org/layers/+misc/parinfer/README.html) mentions how to switch between the 2 modes: > SPC t P Toggle between parinfer indent and paren mode

💥 4
cullan16:12:12

Hi everyone. I am using Cider and figwheel-main with a clojurescript project. When I try to evaluate an infinite sequence like (repeat 1) I expected it to truncate the result and print it out but I get an error:

Eval timed out!
No stacktrace available.
My browser also complains that the web page is slowing down my browser and I have to kill it and restart. I tried changing cider-print-quota to a much smaller value and adjusting length in cider-print-options but that did not fix the problem. Can anyone here help me out?

yuhan17:12:08

Have you tried setting *print-length* directly? I'm not entirely sure if that works in Clojurescript

yuhan17:12:22

ie. eval (set! **print-length** 100) in the CLJS repl, not elisp

cullan17:12:31

aha! if I do (set! *print-length* 1024) it does truncate the output. Thank you.

cullan17:12:53

Do you know where to save that so it automatically happens in a new repl?

yuhan17:12:28

I have it set in cider-repl-init-code

cullan17:12:42

Nice. I will try to adjust that. Thanks again!