Fork me on GitHub
#cursive
<
2018-03-04
>
emccue02:03:51

does anyone in this neck of the woods have experience using clojure-maven-plugin

emccue02:03:47

I have it to the ppoint where clojure:compile works but regular compile does nothing

emccue02:03:00

Also, im having issues with imports of records not being resolved in java when those records are defined via macros

emccue02:03:40

(i detailed some of the issues in the main clojure thread, and why I think it might be some cursive config)

gklijs07:03:53

I don't know about the plugin, but if you have no java in the project, it seems right that regular compile does nothing. Do you use a :genclass on the clj files you want to use from java?

misha15:03:00

@cfleming greetings! it seems like cursive does not recognize clojurescript's areduce syntax (hope you see the screenshot, slack complains about lack of free disk space):

ckarlsen17:03:06

I have some custom compojure route macros (for non-standard request methods). They look exactly like compojure.core/GET etc. Is it possible to configure Cursive to correctly resolve these custom macros?

mbjarland19:03:50

Anybody seen this kind of issue starting a lein repl within cursive:

Starting nREPL server...
...
Error loading clojure.tools.nrepl.server: clojure.lang.RT.mapUniqueKeys([Ljava/lang/Object;)Lclojure/lang/IPersistentMap;
Exception in thread "main" java.lang.IllegalStateException: Attempting to call unbound fn: #'clojure.tools.nrepl.server/default-handler
?

cfleming22:03:39

@misha https://github.com/cursive-ide/cursive/issues/435, that’s been there for ages, I’ll try to fix this soon.

cfleming22:03:16

@ckarlsen Yes, you can use https://cursive-ide.com/userguide/macros.html. The doc is slightly out of date, there’s now a “Specify…” option in the dropdown which you can use to resolve as any arbitrary macro.

cfleming22:03:58

@mbjarland No, I haven’t seen that. Which version of tools.nrepl are you using?

jonathan23:03:19

hi, I posted this in #beginners but it might actually be a Cursive specific issue as others were not able to reproduce when using nRepl directly. When I print a binding to a multiline string it ignores white-space. But if I call a function on that binding, whitespace is included:

(def multline "aaaaaa
               bb
               cccc")

multline
=> "aaaaaa\nbb\ncccc"
(frequencies multline)
=> {\a 6, \newline 2, \space 30, \b 2, \c 4}
(frequencies "aaaaaa\nbb\ncccc")
=> {\a 6, \newline 2, \b 2, \c 4}

zylox23:03:28

thats intersting

zylox23:03:34

im seeing the same results though

cfleming23:03:52

@jonjanisch @zylox This is an unfortunate feature. Cursive tries to align multi-line strings when pretty-printing, which is often very nice when printing large data structures with multi-line strings. However it has some odd edge cases like this one. You can turn it off at Settings-&gt;Languages &amp; Frameworks-&gt;Clojure-&gt;Split and align multi-line strings.

cfleming23:03:18

I’m increasingly thinking that it shouldn’t be on by default, or perhaps shouldn’t even be a thing.

cfleming23:03:34

For an example of where it works nicely, try (meta #'defn)

zylox23:03:33

ive seen it be valuable in test failure string printing so id say i'm positive on the feature

zylox23:03:50

though @jonjanisch's situation is admittedly confusing

cfleming23:03:53

The issue is that because of the way fipp works, I can’t modify the way it prints strings that fit on a single line, and I can’t tell ahead of time which ones will.

cfleming23:03:39

I should revisit that and see if I can’t hack something there.

zylox23:03:14

nothing like a good old string hack

cfleming23:03:24

I know, right?