Fork me on GitHub
#spacemacs
<
2019-10-04
>
clarice10:10:58

Hello there, I want to refactor a namespace. When I try , r r s on the ns then I get cljr-rename-symbol: Wrong type argument: char-or-string-p, nil

practicalli-john08:10:01

Many of the clj-refactor commands require a Clojure REPL is running. This might be the cause of the error. You may also find projectile-replace a useful alternative for changing a symbol name across a project. There are some more refactor approaches covered at https://practicalli.github.io/spacemacs/refactor/

flefik11:10:19

How can I make copy work in spacemacs when running emacs -nw inside iterm2 on Mac OS?

Abhinav Sharma18:10:07

Hello everyone πŸ™‚ I was wondering if someone could point me to good resources for debugging clojure(script) code via spacemacs ( or cursive). Would be great if you could share your own debugging setup

practicalli-john08:10:21

, d b or M-RET d b to instrument a specific function. When calling that function the the cider-debugger will start and allow you to step through the code and show you the intermediate values along the way. I use this for Clojure code. Not sure if there is the same for ClojureScript, I tend to just use figwheel-main error reporting, the repl and browser Dev tools

Abhinav Sharma09:10:37

@U05254DQM, I gave it a shot and got this working for sure - need to learn the stepping functions for sure πŸ™‚ Thanks!

practicalli-john11:10:26

I just use n for next, seems to be all I need. If I am debugging with a lazy sequence, I may need to use o to step out of the specific expression and evaluate its parent expression. For example if I have a (range) function inside a (take 20 ,,,) function, then I use o to skip outside the range call and call the take expression instead. I havent really used the other debugging options yet.

πŸ‘ 1
πŸŽ‰ 1
Abhinav Sharma17:10:53

Yup, tried that and first time ever - I actually debugged clojure code πŸŽ† The experience is kinda nice, I can’t wait to explore this thing in debugging apart from the repl itself.

mafcocinco19:10:20

newb question: Can someone point me at the documentation for emacs mode (i.e. non-`evil`) for the Clojure layer? Specifically, I'm interested in this: http://spacemacs.org/layers/+lang/clojure/README.html#key-bindings for emacs mode.

theeternalpulse21:10:56

a good tip is if you want to find the major mode name do C-h m which brings you into the current mode help

theeternalpulse21:10:06

you'll see all the minor modes and the current major-mode

theeternalpulse21:10:47

you can usually find a mode name to search and find the project page, or even scour through the code, though backtracing some of the keymaps and stuff are a little tough in emacs

practicalli-john08:10:26

@U6SN41SJC there is a standard substitution you can make for the keybindings M-RET where you see SPC m or , M-m where you see SPC followed by characters C-u instead of SPC u for the universal argument M is meta key, e.g Alt on PC or Option on Mac RET is the return/enter key C is the command key

metal 1