Fork me on GitHub

Should .clava .clj-kondo .lip folder in .gitignore?


For clj-kondo and lsp it is sufficient to add one:

in your .gitignore (so without anything else)

thanks3 3

Don't ignore the whole .calva/ folder. Rather: .calva/output-window/


@U04V15CAJ I think that just .cache is not necessary, see example below using fulcro:

?? .clj-kondo/com.fulcrologic/fulcro/com/fulcrologic/fulcro/clj_kondo_hooks.clj
?? .clj-kondo/com.fulcrologic/fulcro/config.edn
?? .clj-kondo/com.fulcrologic/guardrails/com/fulcrologic/guardrails/clj_kondo_hooks.clj
?? .clj-kondo/com.fulcrologic/guardrails/config.edn


@U936PSSLQ You're supposed to check those files into source control


As they provide better linting for your libraries and your team mates and CI will benefit if you have those files in your repo


is it an idea to put output-window under .cache instead, to separate what should be versioned and what not?


There is nothing cashe-y about it though, so that would be confusing. We can stick a .gitignorefile in there, though. Then users will not have to figure about what should be ignored or not.

👍 1

Is there a way to make backspace in Calva delete all spaces when on a blank line, like the other Clojure editors?


Not sure I understand the question correctly, but what I do is press cmd+backspace. Not sure what the equivalent is on non-macs, but the VS Code command is named Delete All Left. You might be able to get backspace alone do this, if you bind it to Delete All Left with some fancy when context, but it seems a bit unnecessary to me. 😃


This is how Cursive (and Emacs) do it for paredit mode: (I'm just pressing Enter and Backspace alternately here)


Hmm, testing it with Ctrl instead of CMD, (Ctrl-Backspace) and it does some kind of backward splice


But anyway, in my animation above, do you agree that just removing a single space isn't something one would want? I.e., one wouldn't want to start typing at an incorrect indentation level, so the only possible interpretation is that the user wants to delete the line. I think that is the paredit logic in Emacs and Cursive, which I think is correct/useful.


I think the only difference, and it’s a tiny one 🤏, is that cmd + backspace doesn’t seem to move the cursor up to the last non-ws char. But, pressing backspace again will. So, I think, to get the equivalent behavior as Emacs/Cursive @U08JKUHA9, you’d need to do cmd + backspace backspace -holding down cmd the second time is optional.


Yeah, could be argued that it is the only interpretation. I just think it is slightly unnecessary, since there is a VS Code command for it. You can also do cmd/ctrl+land press backspace. That said, if you are willing to provide a PR, I would probably accept it.


Ok. For me I'm so used to the standard behavior that I can't live without it, even if I could hit some other shortcut. So yes - I think I will give that PR a shot.

🙏 1

You can also use the joyride extension 😉 that runs a small script that does cmd+backspace,`backspace` and then bind that to whatever keybinding you want, right? If you want cmd+backspace to exhibit this behavior, then you can change the Delete All Left binding to something else, and then use that in your joyride script instead.


True, but I think this is something pretty important to have a sensible default for, so I don't want to fix it for just myself


Looking forward to that PR! Please file an issue first, @U08JKUHA9.


Let me know if I can help in any way. Here's where you can start if you like to do it TDD style:


Thanks. Plan to start looking at it this evening (I'm on Mountain time)

🙏 1

I'm probably asleep by then. 😃 But @U9A1RLFNV, @U02N27RK69K and @U037TPXKBGS are in timezones closer to yours, so you might be able to get some hints if you ask here. @U037TPXKBGS, in particular, is very familiar with Paredit things.


Dear Calva friends. • Fix: <;up,down> arrow inside map destruction is not working properly> • Thanks to @armed and @alpox! gratitude 🙏 ❤️ calva @alpox not only collects his Contributor badge on the Calva repository with this release. He also provided crucial help, pairing with me on the evaluateCode extension API. With a sane Dx design at that. (I had a less sane design in my drafts.) See for info about this API, and please join the #joyride, to start playing with it.

🎉 4
joyride 2
calva 2

Now with added Joyride power! 💪:skin-tone-2:

😎 3
🎉 2
joyride 1
calva 1

Thank you for giving real world example usage of joyride! When reading the code, I wondered why you'd put clojure-code to be evaled in a string, instead of just quoting it. Then I realized that you want to put code in there. Which reminds me that I often wanted a syntax-quote that doesn't resolve all symbols. I could construct something like this, but it soon gets unmanageble. Maybe if :evaluateCode supported sending in an context?

(list 'let ['symb (list 'str "#'" code)]
        '(str ""
              (-> (str (symbol symb))
                  (clojure.string/replace "?" "%3f")
                  (clojure.string/replace "!" "%21")
                  (clojure.string/replace "&" "%26"))))


@U04V70XH6 Not really a question but I was curious about your reasoning around choosing to put clojure code in strings.


Yeah, it's definitely one of those "no options are great" situations.


Part of it was because I ported it from an environment where it was all strings.