Fork me on GitHub
#vim
<
2019-11-15
>
martinklepsch11:11:59

Does gq work for you on docstrings?

dominicm11:11:45

What don't you see?

dominicm11:11:59

Maybe I use gw on them

herald14:11:04

gq has never worked for me on docstrings, but I just tried gw and that worked (never heard of it before)

dominicm14:11:36

They are shades of the same action

nate14:11:04

As a part of that interaction, I learned about gw and switched to it because it's slightly better anyway.

nate14:11:02

It does what gq does and then puts the cursor back in the original position.

dave14:11:48

i've also gravitated towards gw. what set me on the path was that fireplace required an active connection in order to do gq

dave14:11:21

or maybe that was =? my memory is fuzzy

martinklepsch15:11:22

Interesting, thanks for all the pointers

martinklepsch15:11:30

I’ll use gw (it works for me too)

martinklepsch15:11:49

With Fireplace’s REPL buffer-less experience, where can I find stdout?

martinklepsch15:11:33

It seems it should be in :Last but isn’t in my case. This is a CLJS REPL and the evaluated from returns a promise.

martinklepsch15:11:26

Seems to also not work when not returning a promise

martinklepsch15:11:29

And seems to work when using CljEval

dominicm16:11:01

There's no persistent connection for stdout.

dave17:11:00

a selling point for conjure 🙂

Olical17:11:04

The reason for the log buffer 😊

martinklepsch17:11:42

> There’s no persistent connection for stdout. Does that mean it’s just not possible?

dominicm18:11:26

It might be, using the API. I haven't looked at that though.

martinklepsch18:11:02

If so I might just have to try Conjure 😄

martinklepsch18:11:38

Is there any docs or notes on using Conjure with Shadow CLJS?

Olical18:11:25

It only half works because shadow's prepl implementation isn't quite right atm 😬 as soon as it's updated to be compliant it'll be fine.

martinklepsch16:11:34

Alright 🙂 I tried it just for the sake of it and am getting this error:

; conjure/out | Welcome to Conjure! (v2.1.1-0-g52618ff54b)
; conjure/up | Adding :functions
; conjure/err | Error from :functions java.io.IOException: Stream closed
; conjure/up | Done.
; conjure/up | Removing :functions
Is this the expected behavior at this stage?

Olical11:11:11

Yep, I'm afraid so. As soon as shadow is compliant, Conjure will work. Might be worth mentioning interest in #shadow-cljs, if the maintainer(s?) see interest in prepl it might help motivate development. I wouldn't bug them about it though, they know it's wanted, probably just don't have time to get around to it. I'm not pushing them to get it working, I'll see if I can contribute more at some point to help out, just showing interest might help with motivation I think.

Olical11:11:22

It'll be awesome when it works!

Olical11:11:56

Conjure works with any compliant CLJ or CLJS prepl (my terms), if something's a little broken, it's probably the prepl server more than Conjure as a client. Conjure is fairly simple in the grand scheme of things, the most complexity is beginning to lie in the UI which I'm actually rewriting in a Lisp that compiles to Lua soon, should help tidy the UI code up and make it a lot fancier. (I'm even considering animating the log buffer opening 😬 )

Olical11:11:37

https://oli.me.uk/clojure-prepl-for-tool-authors/ I link it a lot, but this post explains how a prepl should work, it's what tool developers can use to make sure they're speaking the same lingo.

Olical11:11:07

It's the only definition online AFAIK, I think I'm the biggest consumer of prepl at a tool level at the moment... I've spent a long time digging through the source.

tpope18:11:50

some sort of log buffer was on the roadmap for future clojurists together funding. but it feels weird to need it

tpope18:11:13

but i also recall stdout being ten kinds of janky with cljs, maybe that's a factor?

dominicm18:11:31

Very helpful for async.

👍 4
dominicm18:11:47

Especially in clojurescript, when you're testing promises

martinklepsch18:11:56

Given that println debugging is basically my go-to “technique” it would be quite limiting

martinklepsch18:11:24

In my limited testing it didn’t seem that promise or no promise made a difference

tpope18:11:36

that points to my ten kinds of janky suspicions

dominicm18:11:57

You should get output generally, just not in an async context

tpope18:11:20

it might have even been a shadowcljs issue? i can no longer remember

Olical18:11:47

I think it's very workflow dependant. I like the history in a buffer as something I can edit and reeval because I'm EXTREMELY forgetful.

dominicm18:11:15

If you do :Eval (println 1) and you don't see 1, something is wrong

👍 4
tpope18:11:29

yes do that