This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2017-03-30
Channels
- # bangalore-clj (1)
- # beginners (23)
- # boot (1)
- # cider (23)
- # cljsjs (2)
- # cljsrn (4)
- # clojure (251)
- # clojure-dusseldorf (2)
- # clojure-gamedev (23)
- # clojure-italy (5)
- # clojure-russia (53)
- # clojure-sanfrancisco (5)
- # clojure-spec (7)
- # clojure-uk (66)
- # clojurescript (169)
- # community-development (21)
- # core-async (10)
- # cursive (15)
- # data-science (1)
- # datomic (7)
- # docker (1)
- # emacs (24)
- # events (1)
- # funcool (6)
- # hoplon (24)
- # liberator (1)
- # luminus (6)
- # lumo (62)
- # mount (7)
- # off-topic (1)
- # om (12)
- # om-next (5)
- # onyx (14)
- # overtone (2)
- # pedestal (58)
- # powderkeg (27)
- # protorepl (1)
- # re-frame (1)
- # ring-swagger (16)
- # rum (51)
- # spacemacs (25)
- # uncomplicate (7)
- # unrepl (22)
- # untangled (7)
- # yada (109)
@anmonteiro @mfikes Thanks!
@cfleming Planck also now supports -V / --version
and -D / --dump-sdk
if you do brew install --HEAD planck
I'll likely further shore up the code and also of course address any behavioral changes we find are necessary, but the first cut appears to be working.
@cfleming If you end up supporting Lumo and Planck via Cursive's "normal" project.clj
infrastructure, both Lumo and Planck accept -c
and a regular Java-style classpath. Neither Planck nor Lumo directly support lein
but they are both often used by feeding lein
-generated or boot
-generated classpaths.
Having Cursive being able to introspect the bundled SDKs is something I've never seen before. I took a sneak peek at what it might look like.
@mfikes @anmonteiro When people are working on Planck and Lumo projects, do they tend to use lein for dep management? I guess they need to obtain their CLJS deps somehow?
@hit023 Cursive doesn’t support it right now, but my question was more how Lumo/Planck users manage their deps in general
If it's not much effort, it might be okay to just expect people to have a file like that which contains the cp
@dominicm Thanks for the suggestion, I’ll check it out. But people still need some kind of dependency resolution and fetch, right?
But the existence of a cp file inducing the classpath is a fine thing to have at this point in the lifecycle. And I'm assuming it's minimal effort.
@dominicm Ok, thanks - I think a cp file is a fine idea too. I’ll support that and then add new things as people start using them.
Thanks - I don’t really need it for anything specific, but the comments above made me wonder about it.
I’ve only used Lumo for one-off scripts, so hadn’t considered deps, or at least CLJS ones - I’d assumed it was all node_modules
Yeah, I can understand that. It may be a WIP to add it (I believe as a desire for caching)
It's difficult to consume cljs from a node modules folder due to differing semantics.
Mach did look into the node modules folder for a while, and still does a little (unnecessary now 1.2.0 is out). But the jar solution is better. The hard part now is figuring out the classpath arithmetic that maven does for a (cl)js port
Yeah, it’s a bit weird - you really want something with deps resolution (lein or boot) somewhere in the mix
Perhaps I could just get people to download their deps to a libs folder and use everything I find in there - I assume boot can do that trivially.
In general, I think my best option is going to be to just rely on the built-in IntelliJ functionality for now. That supports all sorts of different configs, and will allow pretty much anything. The only thing is it’s manually configured and not in some declarative file.
@cfleming I've been using boot -d dep:ver to download the dependencies I needed, then I use lumo -c <fullpath to jar in .m2 directory>
Is there a way to start a repl in a namespace? lumo -e "(require 'my.core)" -e "(in-ns 'my.core)" -r
doesn't seem to work
@pesterhazy can you do that in the raw clojure.jar?
If it's possible we should support it. Otherwise, that has been my rule of thumb
let me check
It works:
java -jar ~/.m2/repository/org/clojure/clojure/1.9.0-alpha14/clojure-1.9.0-alpha14.jar -e "(in-ns 'clojure.set)" -r
@cfleming Neither Lumo nor Planck do deps management and only accept a -c
for the classpath. I suppose they are analogous to if you were to start a bare Clojure REPL, which also does no deps management. There is a section on Lein and Boot here http://planck-repl.org/dependencies.html
@pesterhazy @anmonteiro That may work in Clojure only because in-ns
is a function in Clojure. In ClojureScript it is a REPL special—perhaps that's the root of the -e
problem.
$ planck -e "in-ns"
WARNING: Use of undeclared Var cljs.user/in-ns at line 1
$ lumo -e "in-ns"
WARNING: Use of undeclared Var cljs.user/in-ns at line 1
nil
@mfikes interesting. Maybe an --init-ns
arg would be better?
For background, I like to have a dev
script that opens a lumo repl opened in my user namespace
@cfleming are you going to handle node.js objects/events code completion?
That is the feature that I am seeing very powerful in vscode
@richiardiandrea So yes, to some degree, but I’m not sure quite how yet
I was looking into ternjs
that could be a shared module between editors
given that we can kind of compile to JS on the flight, we could get pretty fancy 😄
oh cool
I’m planning to do more sophisticated inference in Cursive, but it’s a hard problem/large project
yeah true that, it would be great to make it available to other editors and if you do that probably I can help 😉
@richiardiandrea Unfortunately whatever I do probably won’t be reusable, since it’ll be intertwined with the IntelliJ infrastructure
Well Tern runs as separate executable if I read it correctly too it might be straightforward to just call it from inside IntelliJ, but maybe I am totally off here 😀