This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
- # announcements (13)
- # asami (43)
- # babashka (35)
- # beginners (175)
- # calva (23)
- # cider (5)
- # clj-kondo (68)
- # cljsrn (4)
- # clojure (61)
- # clojure-australia (7)
- # clojure-europe (20)
- # clojure-gamedev (59)
- # clojure-israel (11)
- # clojure-italy (4)
- # clojure-nl (2)
- # clojure-norway (21)
- # clojure-spec (12)
- # clojure-uk (43)
- # clojurescript (9)
- # cursive (56)
- # data-oriented-programming (5)
- # datascript (1)
- # events (1)
- # fulcro (16)
- # honeysql (46)
- # leiningen (1)
- # malli (4)
- # off-topic (12)
- # pathom (46)
- # re-frame (24)
- # reagent (14)
- # reitit (1)
- # reveal (8)
- # rewrite-clj (16)
- # ring (13)
- # sci (9)
- # spacemacs (14)
- # specter (2)
- # sql (2)
- # tools-deps (1)
- # vim (2)
For anyone with some time to spare and a heart beating for the newcomers to Clojure or to Calva. https://11500-125431277-gh.circle-artifacts.com/0/tmp/artifacts/calva-2.0.173-814-connect-without-project-fa899f87.vsix) you can help me test. Here’s the relevant documentation page (outdated now, since I have changed my mind about some things while testing this, but still the spirit of the change should shine through). https://github.com/BetterThanTomorrow/calva/blob/814-connect-without-project/docs/site/getting-started.md
For comments on the guides. I’m not sure how to collect those in an efficient way. For now, use this issue that @U01NAG0N7FS started: https://github.com/BetterThanTomorrow/calva/issues/1039
Hi! I'm migrating to calva these days, and so far it seems really nice. The one big disappointment so far has been code formatting, since cljfmt has issues with some variants of namespaced keywords: https://github.com/weavejester/cljfmt/issues/106. I know this is a problem that can only get fixed by people doing the job for free, se I'll just have to wait or do it myself. But my question is: Since I've heard so little about this, is the majority of clojure developers not using namespaced keywords in their codebases?
I never used cljfmt in projects until the current project. There are some interesting formatting rules but some do not seem to fit my workflow. I think I disabled most of them in the end. I don't believe an effective workflow should be constrained by formatting. Cljfmt is an interesting project, although it's not the canonical way to format Clojure code (according to the cljfmt project readme).
That's certainly true. But for 95% of my code layout, I fall back to just applying default formatting. It's particularly convenient for when you want the right side aligned in maps and lets. IMO that quickly gets out of sync if I don't auto format
I do use auto-formatting, via Emacs. which I just starting with LSP and cljfmt. Calva is a much smoother experience, but I still have a lot to learn. Hope you find some good suggestions.
I think namespace keywords is very common. I think that it might be the namespace alias syntax that is problematic for the formatter, and maybe not as common. I think that the one who knows the current state of this as far as
cljfmt is concerned might be @UE21H2HHD (because he knows stuff about
rewrite-cljc). Then there is also that Calva uses an aging fork of
cljfmt. There was work started to merge in latest, but it seems to have stopped. https://github.com/PEZ/cljfmt/pull/2
I think it is with reach to make Calva use something like
zprint for formatting (still would take a focused effort), but I also think it would run into the same problem. Since upstream it looks the same for both….
Another option we have is to rely on Calva’s indenter as a backup. Then we wouldn’t get full formatting when we hit this problem, but at least get things indented. Of all options I see, this is the one with the least effort needed.
Hi folks! This issue will be addressed in rewrite-clj v1 which I am currently pushing toward an alpha release.
So, then maybe if I update my cljfmt fork and make it use rewrite-cljc we can let Calva users opt in on testing it that way.
rewrite-cljc is dead, but is reborn in the clj-commons/rewrite-clj v1 branch (which when ready, will be merged to main)
Thanks for your effort on rewrite-clj, @UE21H2HHD, very impressive. And I'm totally ready to test the calva integration on the bleeding edge 🙂
We use the namespace alias syntax a lot, and I also use auto formatting a lot, so I'm heavily affected by this bug.
I just posted this question in #reveal, but I’m not sure if it fits better over here, so I’m posting a link over here, hoping that someone recognizes my issue… https://clojurians.slack.com/archives/CUDTFQ152/p1613742962110400
I’m starting to suspect the Java version that I’m using. I’m using AdoptOpenJDK 8, and it seems with AdoptOpenJDK 11 it works better. I’ll test a bit more.
There a keyboard shortcut for tapping. So maybe the deps-only option could work pretty well?