This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2018-07-30
Channels
- # arachne (5)
- # beginners (42)
- # cider (35)
- # cljs-dev (25)
- # cljsrn (2)
- # clojure (107)
- # clojure-dev (32)
- # clojure-finland (2)
- # clojure-greece (3)
- # clojure-italy (6)
- # clojure-nl (7)
- # clojure-spec (27)
- # clojure-uk (45)
- # clojurescript (152)
- # core-async (3)
- # cursive (26)
- # data-science (4)
- # datomic (33)
- # defnpodcast (1)
- # duct (12)
- # editors (3)
- # emacs (6)
- # events (5)
- # fulcro (6)
- # jobs (1)
- # lein-figwheel (9)
- # off-topic (7)
- # onyx (7)
- # re-frame (1)
- # reagent (9)
- # reitit (31)
- # shadow-cljs (130)
- # slack-help (1)
- # spacemacs (53)
- # tools-deps (55)
- # yada (4)
I think there’s no listing of the options anymore because now they are dynamic and they used to be fixed in the past. I’m not sure if defcustom
has support for handling a dynamic list of options.
But it’s the issue you mentioned is certainly odd - like something to do with missing hack-variables
or something (needed for dir-locals to work with non-file buffers).
I’d like to solicit a bit of feedback on updating piggieback for nREPL 0.4 from everyone. Please, take a look here https://github.com/nrepl/piggieback/pull/92 and let me know how this looks to you. Some help with the mysterious error will also be appreciated!
I have a git repo with a deps.edn
in a sub directory but no project files at the top level — is there any way I can run cider from that sub directory?
ahhh — I got confused because it asked me which command to use which made me think it couldn’t figure it out but it’s really just because the project has project.clj and deps.edn
Thanks @bozhidar 🙂
Yeah, exactly. When there are several potential project targets we leave it to the users to decide what exactly to be used.
Good stuff. That new cider
command is really nice 👍
I used to use “Eval & pretty print” quite often but noticed that this has been removed (I think?). I found the inspector thing - which is cool but requires me to know how to use it :D Is there any chance pretty printing will come back?
@martinklepsch It was never removed. 🙂
Just the keybindings changed recently, as there were many pprint-related commands and we moved them in a dedicated keymap, so people can find them easier.
* **(Breaking)** Move `cider-pprint-eval-last-sexp`, previously on `C-c C-p`, to `C-c C-v (C-)f (C-)e` in the `cider-eval-commands-map`.
* **(Breaking)** Move `cider-pprint-eval-defun-at-point`, previously on `C-c C-f`, to `C-c C-v (C-)f (C-)d` in the `cider-eval-commands-map`.
Btw, I’m happy to report that I sorted out the piggieback situation and now 0.3.7 is out with support for nREPL 0.4. It will still work with the legacy tools.nrepl, so piggieback users won’t experience any issues if they are still using it.
so now, aside from using piggieback 0.3.7, is there anything special that needs to be set up to have nREPL 0.4 in CIDER?
We just need to cut a stable 0.18 release and afterwards I’ll update the mainline middleware.
I’m playing with the idea to update the middleware straight in 0.18, but I’m not sure if I’ll have time and energy for this. 🙂
Generally now it’s very easy to get 0.4 going with clj
or the lein nrepl
, but lein repl
requires you to be running lein
from master
. (and you have to use cider-nrepl-0.19-SNAPSHOT
which I’ve build especially for early adopters).
If someone goes over all the cider-nrepl
code and applies conditional requires like here https://github.com/nrepl/piggieback/commit/2f38ab2a7cf84061fc1a744c9a8e91660b3c3ac9#diff-748325368821931b8d3cdb2efc2a7586R19 we can have the support for 0.4 even now.
Probably doing things in this manner would be preferable to dropping support for tools.nrepl
directly, though (which is what I did in the 0.19 branch).
Hi there, how can I evaluate just part of the function or one specific expression in comment? for example:
(comment
(def server (-main "--port" "8080")) ;; just this one
(web/stop server))
@chokheli there are several ways.
1. put cursor at the end of the expression and press C-x C-e
2. there is an insert into the repl type of evaluation. There's a useful way to make things insert into the repl and eval automatically there which I like.
(setq cider-invert-insert-eval-p t)
(setq cider-switch-to-repl-after-insert-p nil)
The first of these makes forms put into the repl with the insert commands eval automatically rather than requiring you to hit enter. The second prevents the point from moving into the repl buffer.
3. You can redefine what top level defun means.
(setq cider-eval-toplevel-inside-comment-form t)
will make eval-ing top level defun aware of comment
forms like this and make it do the right thing. If your point is inside the form, evaling (or inserting) into the repl using a top level defun command will work on what you mean and not the whole comment form which returns nilThe insert commands are nestled inside of a keymap at C-c C-j
. There you'll find e
for last expression, d
for top-level-defun, r
for region and one other one
https://github.com/clojure-emacs/cider/commit/35cf253ff35596dbf48925291ec76eac3b234fdc
If you use cider-eval-toplevel-inside-comment-form
there is a bug with autocompletion inside of comment forms at the moment. If you retoggle it off the bug goes away. There is a disagreement of what begginning-of-form means. I need to fix it
If you want to hear the dulcet tones of the one and only @bozhidar https://soundcloud.com/defn-771544745/36-a-long-glass-of-cider-with-bozhidar-batsov-aka-bbatsov
i'm trying to get a nrepl connection via figwheel. im not sure what versions of what i should use at this point. for example, it seems like bozidar has done some awesome work and updated the whole setup, im not sure if changes need to be made to lein-figwheel to support this or not. more directly, with more current setup i get this error:
SEVERE: Unhandled REPL handler exception processing message {:op classpath, :session 066f0db1-77c8-42b8-bcc0-67610738112b, :id 9}
java.lang.IllegalArgumentException: No implementation of method: :send of protocol: #'nrepl.transport/Transport found for class: clojure.tools.nrepl.transport.FnTransport
its possible i should open a more formal github issue, but its not clear with who and about what.