This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2018-04-17
Channels
- # aws (10)
- # beginners (64)
- # boot (3)
- # cider (20)
- # cljs-dev (32)
- # cljsrn (6)
- # clojure (126)
- # clojure-dusseldorf (3)
- # clojure-finland (1)
- # clojure-greece (1)
- # clojure-italy (7)
- # clojure-poland (3)
- # clojure-spec (46)
- # clojure-uk (100)
- # clojurescript (37)
- # cursive (11)
- # datomic (6)
- # defnpodcast (2)
- # emacs (1)
- # events (3)
- # figwheel (2)
- # fulcro (20)
- # immutant (2)
- # jobs (1)
- # jobs-discuss (9)
- # keechma (3)
- # lein-figwheel (1)
- # luminus (2)
- # lumo (3)
- # mount (2)
- # off-topic (19)
- # om (3)
- # om-next (2)
- # onyx (20)
- # other-languages (55)
- # parinfer (11)
- # pedestal (8)
- # portkey (3)
- # protorepl (3)
- # re-frame (22)
- # ring (9)
- # rum (1)
- # shadow-cljs (82)
- # spacemacs (28)
- # sql (15)
- # test-check (15)
- # testing (2)
- # tools-deps (102)
- # vim (26)
change it in package.json
and then run npm install
. restart shadow and it should pick it up
Do you know the consequences of having a global install that’s out of sync?
it always uses the one installed in the project over the global one so it should not be a problem.
I'm getting "Too many open files" error every now and then:
[:app] Compiling ...
[:app] Build failure:
FileNotFoundException: /home/matthys/projects/personal/learning/src/learning/web/topic_notes/core.cljs (Too many open files)
java.io.FileInputStream.open0 (FileInputStream.java:-2)
java.io.FileInputStream.open (FileInputStream.java:195)
java.io.FileInputStream.<init> (FileInputStream.java:138)
(io.clj:229)
(io.clj:229)
(io.clj:69)
(io.clj:165)
(io.clj:165)
I can create an issue for this, but not really sure what information I can provide. How would you go diagnosing this?
@mjmeintjes if you are on linux/osx you can use lsof -p <pid>
to list the open files of the shadow-cljs process. jps
should list the pid. not sure where the leak could be coming from so knowing which files are open would help a lot
might also be an external process with too many files open though. doesn't have to be the shadow-cljs process since its a user limit not a per process limit IIRC
Thanks, that helps. If it happens again I'll open an issue if it looks like shadow-cljs is at fault.
@thheller: I edited the github project wiki to add info about Calva for editing shadow projects: https://github.com/thheller/shadow-cljs/wiki/Calva
(I know it said deprecated, but didn’t see how to edit the other user guide, and people will look at the wiki pages as long as they are there anyway.)
cool thx. I will add it to the user guide later. or you send make a PR if you want https://github.com/shadow-cljs/shadow-cljs.github.io
https://github.com/shadow-cljs/shadow-cljs.github.io/blob/master/docs/editor-integration.adoc
@pez: I want to say that I took Calva for a spin yesterday with a shadow-cljs project I have here and so far it looks really good
like, “maybe I can finally stop scaring off the youths with my and then you simply download 'emacs'...
speech when trying to infect them with The Clojure” good
I will have to dig through the extensions list and see if there’s anything that can hold a candle to magit
and org-mode
before get too serious about Code as a daily driver, but Calva seems to do really well for a REPL 🙂
The org extension doesn’t seem to match emacs org-mode very well. But GitLens together with the built in Git support is very good, I think. Maybe not magit
-level, keyboard-wise, but still good.
well, that’s certainly true, but I do think that being able to demonstrate the REPL workflow in a “modern editor” might get some of those “weaklings” interested enough to start lifting some mental weights, so to speak
My experience has been that the vast majority of devs, once they see the REPL flow work, they will happily chew on emacs
or JVM stacktraces or whatever for awhile to get what I’m selling hehe
I think I should put together a playground project for people to try out shadow-cljs together with the interactive programming Calva enables.
If you play some with Calva for shadow-cljs, I am eager to learn if something does not work or if there is something that would make the experience better.
I intend to use it for my interactions with the project I mentioned before (shipped, production SPA but that I don’t have many responsibilities over) and also when I spike moving our RN app from Boot to shadow-cljs sometime Real Soon™
Actually, it seems there are some problems evaluating (loading) files in the Clojurescript repl of shadow-cljs. This works more stably in Figwheel’s repl. I have some investigation to do.
couldn't get it to work properly. it seems weird to me that it forces me to select a CLJS repl before I actually do anything.
ie. in my work project I usually have 2 builds running. say one for the server one for the browser. if Calva tries to unconditionally load the CLJS file I'm currently working on in the REPL that will cause problem
It defaults to autoconnect. This is a setting. Maybe it should default to not do that. But I am not sure that is the whole story behind what you mean with “my approach”?
same for two different :browser
builds. I have one for the website and one for the admin interface
I will have to go back to the drawing board for properly supporting shadow-cljs, I think. Can you tell me how you would like it to work?
in CLJS it is not since there are many different platforms and it is very likely that you'll be talking to many at once
say you build a react-native app and have the app open in iOS and android. which do you use to eval the REPL code in?
it just sends the eval to everything that is connected and displays the first result that comes back
But if we put that problem apart, which seems to be much bigger than Calva… Maybe if for shadow-cljs projects Calva asks for which build for every file that is opened? Possibly trying to remember per file between sessions.
You can’t at the moment. Well, maybe you can reconnect and that has that effect, sort of.
this may be a stupid question, can i set different :output-dir
for :dev and :release? it seems the answer is yes from the docs... but maybe i am having a slow day and can't see it clearly.
use case is i have watch
running but i also have a quick test deploy
script the compiles the same build but in release
and deploys to surge.sh.
so TLDR: can i run a release build if the same build is being watched? if so.. how do i set a different output folder?
https://shadow-cljs.github.io/docs/UsersGuide.html#_release_specific_vs_development_configuration
@thheller I just published an update of Calva that does not auto evaluate files. Might make it an opt-in later, but this is a saner default considering all different kinds of workflows and project setups. I’m still pondering on how to support build switching. For now reconnecting might work. Please let me know if you try it out some more, what works and not.