Fork me on GitHub
#calva
<
2019-12-09
>
teawaterwire11:12:18

hey - does "peek definition" work for cljs? i'm struggling to make it work - or i'm missing something

dabrazhe13:12:42

@pez the test resutls above is for a Windows 10 machine. I can try on a Mac at home if you really need it.

pez15:12:03

@dennisa, it’s fine. I am using Mac. The implementation is different between the two, so it is good you can test on Windows once there is something to test. Help me remember by adding an issue about it.

pez15:12:24

@teawaterwire yes, it is supposed to work for cljs. Two questions: 1. Have you evaluated the file? 2. How did you connect Calva to the project?

teawaterwire09:12:24

hi (sorry for the delay) 1. i didn't evaluate the file 2. i'm running shadow server and shadow watch app then connecting via "connect with existing REPL"

pez11:12:05

Try letting Calva start the repl for you (aka Jack in). If that works, then the problem is that the project does not have the dependencies Calva needs.

teawaterwire14:12:18

ok let me try that :thumbsup:

teawaterwire14:12:57

oh yeah it works indeed! when jacking-in i saw it downloaded cider stuff so i guess these are the deps missing

pez16:12:21

Great. You can read some about jack-in and connect here: https://calva.readthedocs.io/en/latest/connect.html

pez16:12:01

And if you really want to figure out jack-in: https://calva.readthedocs.io/en/latest/jack-in-guide.html 😃

Ilya16:12:22

Hello all, I’ve really enjoyed using Calva with VSCode, just the inline REPL evaluation makes is worth it. Awesome.

Ilya16:12:59

With a project/Jack-in REPL, how would I go about setting an environment variable?

Ilya16:12:17

I’ve set one by starting a REPL at the terminal e.g. MY_ENV=hello lein repl and then using the “connect to a running REPL” but wondering if there’s something for a project/Jack-in REPL

pez16:12:42

Glad Calva brings enjoyment, @ilyab ! There is a JackInEnv setting. See if it does what you want it to do.

Ilya16:12:24

Thanks @pez that works! And nice listening to you on the defn podcast 🙂

pez17:12:06

Awesome. That defn episode was a blast to record. 😃

pez17:12:52

^ That ^ was for @hoppy , but all of you are welcome to give test it for me.

hoppy17:12:21

naturally, that one seems to work perfectly :face_with_cowboy_hat:

carmen18:12:38

hi @pez, two questions: 1. I was the one that contributed this tip originally https://calva.readthedocs.io/en/latest/customizing.html#wrap-using-like-cursive but i can't get it to work anymore with the most recent updates. any ideas on how to achieve this behaviour now? 2. I can't remember how I had this working before -- how do you prevent the deletion of parens when the deletion would cause unbalancing? (ie. if i hit backspace on (foo) then the closing paren shouldn't be deleted)

carmen18:12:19

2. was because i deleted the bindings for "Delete backward" and "Delete forward"

Filipe Silva18:12:35

2. is strict mode

carmen18:12:49

that's what i thought, but it's still deleting 😞

Filipe Silva18:12:04

there was recently a big paredit update

carmen18:12:28

yeah, i know. i had to redo a bunch of bindings 🙂 got everything working except for these two lingering issues

carmen18:12:01

hm, i think i deleted the backspace binding. do i need it bound to a calva command?

carmen18:12:03

aha, the answer is yes 😛

Filipe Silva18:12:04

do you have any setting changing strict mode? I had one disabling it from a few months ago and had to remove that setting from the json

Filipe Silva18:12:51

now whenever I go into a clj or cljs file all those bindings just work automatically, but outside those files they do other things

pez19:12:35

@carmen, so 2 is good now? I’ll have a look at 1 now.

carmen19:12:12

2 is good! that was my own fault 🙂 thank you!

metal 4
pez19:12:21

So, 1 is like the built-in vscode behaviour, but you don’t want to have to press left-arrow after?

pez19:12:06

And by it not working you mean that it keeps the selection, or something else?

pez20:12:52

nag, nag, @carmen ^

carmen20:12:47

@pez yes to both

carmen20:12:40

i'm looking to mimic the intellij behaviour, where i can select a form, wrap it with something and then the cursor ends up on the left so like [foo] to (|foo)

pez21:12:37

@carmen Currently it can’t be done, because when rewriting Paredit I spent some time making sure the selection was retained… 😃 I could change that, because that behaviour is already built in to vscode. Please file an issue about it. It’s an easy enough fix, but I need to think about the implications some.

carmen21:12:05

Ok, thanks for looking into it!

Stefan T23:12:51

I’ve been running into an issue today, it seems calva repl commands are active in json. I’m unable to edit json files and getting this warning Running the contributed command: 'calva.replWindow.cursorDown' failed.