Fork me on GitHub
#calva
<
2022-08-27
>
plexus10:08:47

Hey folks, am I missing something or are there no installation instructions on https://calva.io?

pez10:08:26

For installing Calva? That might be missing.

plexus10:08:27

Seems like an important step 🙂

pez12:08:23

I have not thought it was worth instructing about something so easy. And so far no user has ever asked about this. But now I've added it anyway, for completeness: https://calva.io/getting-started/

❤️ 2
hanyuone14:08:22

Hello! I'm trying out Calva with a brand-new project generated with deps-new, but I'm not sure how to integrate Jack-in with my project? I'm trying "Jack-in" > "deps.edn" > no alias, but when I try alt+enter on any top-level function there's no output, not even a nil

pez14:08:11

Is the repl status bar item indicating that the the repl is connected? What do you see in the repl output window?

hanyuone23:08:19

It indicates that it's connected, and I'm getting this as output:

clojure -Sdeps '{:deps {nrepl/nrepl {:mvn/version,"1.0.0"},cider/cider-nrepl {:mvn/version,"0.28.5"}}}' -M -m nrepl.cmdline --middleware "[cider.nrepl/cider-middleware]"
nREPL server started on port 33571 on host localhost - 

pez06:08:07

That looks good. It is what we refer to as the jack-in terminal. There should also be a file/document showing with some welcoming message and repl output. If it's not showing you can open it with a command. Search the command palette for something like “Calva output” and you should find the command.

pez16:08:14

Thanks for the heads up! I've answered.

plexus16:08:38

When I connect to a running nREPL server (so no jack-in), why does calva still ask what the project type is?

pez16:08:12

I'm not recalling all the details here. But one reason is so that we know which nrepl port file to look for.

plexus16:08:17

I didn't realize that differed among tools.

pez16:08:16

It does. 😃 A second reason is to know if we should start and/or connect any ClojureScript REPLs. And if we should we want to know a thing or two about the project in order to present the right options to the user.

plexus16:08:08

Thanks for elaborating. That's really helpful. Do you have any mechanism for configuring these things on a project level so the user doesn't always get these prompts?

plexus16:08:09

in emacs one of the first things I do on a project is set up a .dir-locals.el so that CIDER doesn't bother me with the same questions over and over again 🙂

pez16:08:36

Yes, search for connect sequences on http://calva.io

plexus17:08:14

Thanks, I found this. Is this something I configure inside vs code, or does it go into a file in the project? https://calva.io/connect-sequences/

pez18:08:09

It's vscode settings that can go either in user (global) or workspace/project. Search the command palette for JSON and you should find commands for opening either of these. I think they make most sense in the project.

pez18:08:15

Also, you can reach these settings from the Settings view. The Ux is a bit unclear I think, but User and Workspace are tabs.