This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
- # admin-announcements (48)
- # alda (1)
- # aws (24)
- # beginners (4)
- # boot (103)
- # cider (69)
- # clojure (111)
- # clojure-art (5)
- # clojure-dev (35)
- # clojure-greece (2)
- # clojure-nl (3)
- # clojure-russia (1)
- # clojure-shanghai (1)
- # clojurescript (220)
- # clojurescript-ios (1)
- # clojurewerkz (3)
- # community-development (3)
- # core-logic (5)
- # cursive (5)
- # datomic (24)
- # devcards (21)
- # editors (3)
- # funcool (1)
- # hoplon (20)
- # ldnclj (47)
- # ldnproclodo (1)
- # liberator (1)
- # off-topic (7)
- # om (21)
- # onyx (36)
- # reagent (1)
- # ring-swagger (2)
- # spacemacs (38)
- # yada (17)
Is there any reason that cider can only eval the sexp immediately before the point? When outputting to minibuffer, that is. In vim-fireplace, I could just stand somewhere inside a sexp and have it be evaluated. I find it a bit awkward that, for example, for the last sexp in the file, I have to create whitespace immediately after, just to eval it.
Something to eval the "parent" would be useful though, that's right - but you could write something in Elisp using Paredit+Cider for that
On your last point... I'm not sure why you'd need that, jumping to the end of the file will put point behind the last character, not over it, right?
Now, if I eval to minibuffer here, I will receive the result "3", as I am evaluating the sexp before the point
Nothing wrong with evaluating a nested sexp - I could do that the same way with vim-fireplace.
But (currently) I still find it a bit awkward. If I wanted to eval the entirety of ( 5 (+ 2 1)) with vim-fireplace, I could choose to do so if the point was on the first (, the , the space between * and 5, the 5, the space between the 5 and the second (, or on the last ).
Is it just me, or does that seem... easier? Than having to navigate to after the sexp.
Ah well, I found a way to do what I wanted to do after all - cider-eval-defun-at-point. My bad!
Well @chipf0rk , I am not sure - I haven't had the need yet. I'm just a newbie sparetime Clojure dabbler
my point is that it can be useful to depend directly on where point is and eval anything inside sexps, including things like just vars
All of the emacs/lisp terminology is perhaps a bit overwhelming for me at the moment Being new to both emacs and lisp, and having English as a second language. So I might misunderstand some things.
Don't worry, I'm an Emacs noob too... The whole system of different terminology for things like cursor, window, ... certainly doesn't help
Hm. I bet I'll get used to it. It just seems weird that I can shoot stuff with my gun, I just have to remember to aim next to the thing that I want to shoot rather than right at it x)
I guess if you come from vim, it's a bit of a change that the cursor being "on" something is more like being "before" it
What's the command called? (I don't have Paredit, but perhaps I have an equivalent)
I’m trying to get going with emacs and cider via spacemacs. When I try to send my buffer to cider in a clojurescript project, I get this error:
No such var: clojure.core/require-macros
Well, this specifically is not really a limitation. You just didn't start the cljs repl :)
You need a cljs repl. There are many different ones, but if you have a look at the CIDER readme there are a couple of suggestions
reefersleep: I guess the logic is that if you're navigating around, then placing the cursor after the sexp is no harder than placing it before. However, if you've just finished typing the sexp (which is a common case), then the cursor is already after it (and so the
C-x C-e behavior is more convenient).
Still, if it's a top-level sexp then you can just use
eval-defun-at-point anywhere (as you've already figured out)
@malabarba: I can see the point in evaluating something you've just finished typing
I’ve opted to keep the CIDER behaviour more or less consistent with the behaviour of Emacs for Emacs Lisp and SLIME for Common Lisp
obviously it’s easy to implement such commands, but there hasn’t been much interest in them
This discussion makes me think that I should make a screencast about Vim-fireplace/sexp commands and motions
Any input on this question I asked last night:
> A question came up on the EmacsLive mailing list about
cider-browse-ns since it seems not to exist, even tho’ EmacsLive bundles CIDER 0.9.1 now. Is there any documentation on how to use the namespace browser? Do you have to be in a particular mode or something?
Why was the change to run tests with clojure 1.8 reverted? I ask because I'm seeing some issues with the pprint ns in 1.8-beta1.
been wringing my head around `clojure.pprint.proxy$java.io.Writer$IDeref$PrettyFlush$4923d848 cannot be cast to clojure.pprint.PrettyFlush`