This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2019-09-04
Channels
- # announcements (5)
- # aws (12)
- # beginners (76)
- # boot (29)
- # cider (24)
- # circleci (9)
- # clojure (64)
- # clojure-dev (27)
- # clojure-europe (3)
- # clojure-houston (1)
- # clojure-italy (33)
- # clojure-nl (19)
- # clojure-poland (1)
- # clojure-spec (6)
- # clojure-uk (20)
- # clojurescript (103)
- # clojutre (1)
- # code-reviews (60)
- # cursive (76)
- # data-science (20)
- # datomic (20)
- # duct (58)
- # figwheel-main (4)
- # fulcro (36)
- # graphql (6)
- # kaocha (4)
- # onyx (1)
- # pathom (15)
- # quil (3)
- # re-frame (15)
- # reagent (15)
- # reitit (9)
- # remote-jobs (2)
- # rewrite-clj (16)
- # ring-swagger (7)
- # shadow-cljs (132)
- # spacemacs (12)
- # sql (5)
- # vim (9)
- # xtdb (12)
- # yada (4)
hey! I've got a problem: I just generated a clojurescript re-frame based project from a template, and tried opening it with cursive. in my code, it says it can't resolve defn
and some other basic stuff.
when trying to Refresh Leiningen Projects
, it errors out with the following message:
Syntax error compiling var at (fipp/ednize.clj:71:13). Unable to resolve var: clojure.instant/thread-local-utc-date-format in this context
after some googling that error should be avoidable by setting an environment variable, but that doesn't seem to work for me. is there some trick needed to get Cursive to respect that variable? or is there maybe another fix for it?
(i'd guess that that load error is the reason for it not recognizing defn
and such)What JDK version are you using?
Ok, that sounds good, what about IntelliJ version? There have been a lot of issues with 2019.1
Ok, I’ve used 2019.2, and not had that problem
Maybe try under File -> Invalidate Caches & Restart?
Ok, maybe your best bet is to downgrade to IntelliJ 2018.3 until they get the bugs fixed in 2019.x
I’m on 2018.3.6, it’s working well
woot!
the "one-space list indent" formatting option is supposed to switch between something like this:
[:div
[:h1 "foo"]
[:div "bar]]
[:div "lkjasdf"]
and this:
[:div
[:h1 "foo"]
[:div "bar"]]
[:div "lkajsdf"]
right? because for me, its always one-space indented which throws me off a looot@lkowarschick The one-space setting only affects lists, vectors always get a one-space indent.
is there any way to change that? it's really confusing to have a mix of one and two-space indentation...
@lkowarschick it's not an identation by alignment of vector's elements...
I mean, it’s possible but honestly I think it’s a tricky solution. To my eye, that looks weirder than just single space vectors.
I suspect that the one-space indent is just something you’ll get used to, much like parens in general. The IdeaVim issue is trickier though. Is there no way to configure that behaviour?
not that i know of... I'd say having a space-padded vector open would be a great solution for this problem, as it would also make indentation more regular in general. generally, I'd love to see comma-first style (like elm uses it) in clojure. it would pretty much be a perfect fit (i know commas are just whitespace, but when used as seperators for longer vecs (i.e. in hiccup) that could increase readability. space-padded vecs would be a great thing though, id love if the cursive team considered adding that option
Does Cursive support :exclusions
in tools.deps?
@danielcompton It should do, yes.
It just delegates all that to deps itself, so if deps supports it, Cursive should too.
I have
tongue {:mvn/version "0.2.6"
:exclusions [clojure-future-spec]}
but I'm still seeing it show up in symbol resolution and in the Clojure Deps browserI do...
The issue is I needed to specify it like this: [clojure-future-spec/clojure-future-spec]
Ooops 😊
Yeah, what is the way to file bugs now?
Does it have to go through Ask Clojure first?
if you have a jira acct, that's fine. otherwise, ask clojure
Ah cool, wasn't sure if that was the new path for everyone
I think you're actually seeing a bug fixed in the last release though
which is that exclusions don't get canonicalized
try clojure-future-spec/clojure-future-spec above and see if that works
Yep, that works
oh you said that above already - I'm reading out of order
Thanks!
so that's fixed in latest already
👍 https://github.com/clojure/tools.deps.alpha/commit/b56370338d2e9a4f7b6d081adf0016d32e6aa8b8
After discovering alt+shift+N a few weeks ago and loving it, I was wondering if there was a similar action to let me search for functions.
I've been using ctrl+f but it's not ideal because it will also find things that are not vars.
@kenny It doesn’t, but it possibly could. It might be tricky, though. What I think will be easier will be to cache the results per module, and only re-read those that have changed. That should work well since normally none of them will have changed, and that’s easier (and probably more reliable) to implement.
That would definitely be helpful. I only ever want to refresh things that changed, not everything.
Oh sorry, I guess that keymap changed from the default somehow. It's Navigate > Namespace
You can search for symbols which will find fns - https://cursive-ide.com/userguide/navigation.html#navigate-to-files-symbols-and-namespaces