Fork me on GitHub
#vim
<
2019-04-10
>
mynomoto13:04:07

Can someone remind me which plugin did pretty print of eval results for fireplace or which middleware I need to add for that to work?

dominicm13:04:03

I need to send a new PR to fireplace, the approach for doing it has changed

dominicm13:04:44

It's annoying because the default can't assume cider, which means that it has to be clojure.pprint/pprint, which is notoriously slow.

mynomoto13:04:56

Ok. Currently there is no way to make it work adding some middleware? Last week I had it working but I did some changes on my setup and I'm not sure if it was me or plugin changes that broke it.

dominicm13:04:32

You probably updated cider

mynomoto13:04:49

Yeah, I did that 😕

dominicm14:04:52

Downgrading will fix it for now

nate14:04:29

What version of cider breaks fireplace pretty printing?

defndaines14:04:39

Anyone using cljfmt? I have one case where it is different from the “automatic” formatting I get from vim, and not sure why. vim edit: (for plugins I have vim-clojure-static, but not vim-cljfmt)

(fn-name
  arg1
  arg2)
After running lein cljfmt fix:
(fn-name
 arg1
 arg2)
cljfmt is removing one space on each line if the first argument to the function is not on the same line. This seems like an exception in cljfmt, where normally it does indent later lines by two spaces, like for let, etc.

dominicm15:04:31

Cljfmt is based on the emacs rules.

Noah Bogart15:04:42

I don't like that rule, lol

👍 4
dave15:04:41

seems like the 2-space rule is more common

dave15:04:50

at least for clojure

dave15:04:59

i can't speak to other lisps

dave15:04:31

my emacs-using coworkers and i sometimes engage in formatting wars because 1-space is the default for emacs and 2-space is the default for vim, lol

dominicm15:04:36

I also have that experience

dominicm15:04:06

Vim users tend to be more precise about what they indent, and emacs users indent the whole thing. It's annoying.

dominicm15:04:15

For reviewing, that is

Noah Bogart15:04:16

I'm not quite on board for tonsky's formatting, but I really don't like how 1-space looks when you're not lining up literals

defndaines15:04:24

That issue was a good read, thanks for posting it. I see the argument for 1 space (tl;dr; it’s still just a “list” and not a special case)

defndaines15:04:09

I do prefer the 2 space, since in the rare case that I use this (it’s pretty rare), it’s because of trying to stack long arguments to a function.

(kinda-long-but-clear-function-name
  ::first-argument-could-be-namespaced/keywoord
  a-map-that-is-also-descriptive-in-its-name)

dave15:04:55

^i do this all the time because i'm an 80-character purist

👍 8
truestory 4
🎩 4
dave15:04:00

(which is a whole separate issue)

dominicm15:04:55

Good to know I'm not alone

Noah Bogart15:04:42

heh Python's Black got me on 88, and I love it

defndaines15:04:14

My .vimrc has set colorcolumn=80 to highlight it for me. 🙂