This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2017-04-25
Channels
- # aleph (6)
- # beginners (6)
- # boot (94)
- # cider (34)
- # cljs-dev (36)
- # cljsrn (12)
- # clojure (124)
- # clojure-dev (41)
- # clojure-dusseldorf (6)
- # clojure-italy (3)
- # clojure-norway (1)
- # clojure-russia (161)
- # clojure-sg (7)
- # clojure-spec (71)
- # clojure-uk (95)
- # clojurescript (38)
- # core-async (16)
- # cursive (14)
- # data-science (1)
- # datascript (12)
- # datomic (15)
- # emacs (22)
- # funcool (2)
- # hoplon (15)
- # jobs-rus (2)
- # juxt (9)
- # liberator (7)
- # lumo (1)
- # off-topic (136)
- # onyx (24)
- # pedestal (39)
- # perun (2)
- # planck (20)
- # re-frame (23)
- # spacemacs (31)
- # unrepl (5)
- # untangled (1)
- # vim (1)
- # yada (29)
Hi, guys! Can someone help me with key bindings? I want to rebind 'cider-eval-defun-at-point
from SPC m e f
to SPC SPC
I guess all magic happening in ~/.emacs.d/layers/+lang/clojure/packages.el
?
If anyone interested — just add in https://github.com/syl20bnr/spacemacs/blob/master/layers/+lang/clojure/packages.el#L98
(dolist (m '(clojure-mode
clojurec-mode
clojurescript-mode
clojurex-mode
cider-repl-mode
cider-clojure-interaction-mode))
(spacemacs/set-leader-keys-for-major-mode m
"," 'cider-eval-defun-at-point)
(mapc (lambda (x) (spacemacs/declare-prefix-for-mode
m (car x) (cdr x)))
cider--key-binding-prefixes)
Now on s-exp simply type , ,
and it will be evaluatedIf add
(spacemacs/set-leader-keys-for-major-mode m
"SPC" 'cider-eval-defun-at-point)
s-exp will work on SPC m SPC
or , SPC
I think , ,
— faster 😃@rustam.gilaztdinov yes, I use a similar binding to show a commented result on evaluation "e;" 'cider-eval-defun-to-comment
@rustam.gilaztdinov you propose a nice binding with , ,
, are you going to create a pull request to have it as part of the clojure layer? I am going to create a pull request for mine, but not until the weekend.
I would like to have a binding that inserts a #_
at the start of an expression, to comment out that expression. Is there such a function already?
I usually rebind C-c C-c to eval the current 'graph under point in whatever language I'm in
typically using emidln//generic-eval-operator and emidln//generic-send-operator, which is a function that sets up eval-sexp-fu overlays for each language. Then I rebind all of the eval/send functions in terms of the the generic operators. Makes it easy so I can just define an alist with mode and a function to take a region and eval/send it with all the plumbing taken care of.
but it's also nice to just have an operator in evil that I can compose up a custom selection and eval it
I have stable emacs-mac installed with brew. Do I need to reinstall it if I want to switch to HEAD ?
@jr0cket what’s your opinion on https://github.com/syl20bnr/spacemacs/issues/8663
I've seen quite a few people mention this issue. I don't use jump (although I should learn too). I'll take a look at the issue at the weekend (need to finish a presentation for a conference on Friday). Thanks
Thanks John, I thought I could work a workaround, turned out to be not so simple as it sounds - the way how Spacemacs handles “jumpers” is a bit tricky
hmm, you can use the function in cider to see if there is a current repl running: cider-connected-p
but it seems you still need to check if the definitions are in the namespace if you want spacemacs/jump-to-definition
to work
On the github issue I've added an example of a keybinding for the clojure layer that could detect the repl is running and use jump-to-definition if it is and fall back on dumb-jump-go if it is not
I had numerous problems with non-GNU versions, every time I try there’s something different. gnu cocoa version works fine for me. Although when installed on linux it feels way more smoother
have you seen this post https://magit.vc/manual/magit/MacOS-Performance.html