This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2017-05-03
Channels
- # aws-lambda (6)
- # beginners (38)
- # boot (39)
- # cider (44)
- # cljs-dev (9)
- # cljsrn (96)
- # clojure (142)
- # clojure-dev (6)
- # clojure-dusseldorf (8)
- # clojure-greece (45)
- # clojure-ireland (3)
- # clojure-italy (7)
- # clojure-norway (6)
- # clojure-russia (26)
- # clojure-sg (16)
- # clojure-spec (31)
- # clojure-uk (39)
- # clojurescript (125)
- # cursive (38)
- # datascript (4)
- # datomic (18)
- # emacs (34)
- # figwheel (2)
- # hoplon (3)
- # immutant (23)
- # jobs (1)
- # lambdaisland (2)
- # lumo (13)
- # off-topic (77)
- # om (8)
- # onyx (9)
- # pedestal (2)
- # play-clj (1)
- # re-frame (52)
- # reagent (3)
- # rum (4)
- # spacemacs (2)
- # specter (4)
- # unrepl (37)
- # untangled (8)
- # vim (79)
- # yada (1)
whenever I create sibling-cljs-repl CIDER would ask “”Visit localhost in a browser? “. I don’t like that, how do I disable?
@ag why would you want this? I'm asking because i'm adding this for you and i need help in naming the var and the docstring
in creating the sibling repl, this is the last expression: (cider--offer-to-open-app-in-browser nrepl-server-buffer)
dpsutton: what’s the convention for naming predicates in elisp? Maybe: cider--offer-to-open-app-in-browser?
(defcustom cider-inhibit-asking-about-browser nil
"When nil, do not inject repl dependencies (most likely nREPL middlewares) at `cider-jack-in' time."
:type 'boolean
:version '(cider . "0.11.0"))
(defun cider--offer-to-open-app-in-browser (server-buffer)
"Look for a server address in SERVER-BUFFER and offer to open it."
(when (and (not cider-inhibit-asking-about-browser)
(buffer-live-p server-buffer))
(with-current-buffer server-buffer
(save-excursion
(goto-char (point-min))
(when-let ((url (and (search-forward-regexp "" nil 'noerror)
(match-string 0))))
(when (y-or-n-p (format "Visit ‘%s’ in a browser? " url))
(browse-url url)))))))
i'm confused about its usage though. do you this set all the time? or just a certain project? would it be a dir local?
i'm not submitting a patch because i don't understand the use case though. would you ever want this to reliably not ask you? would you set a dir-local value? or just global. I don't do much cljs development so it seems strange to me and I want to hear the use case
I honestly think the default should be “not to ask” and the variable that can be set “to prompt” and “to open without asking”
seems like every 8 times I cider-jack-in it takes several minutes
sometimes 10 minutes
can't ever figure out what's going on.
well, I don't think there is an nrepl buffer at the point it 'hangs'...
well, after M-x cider-jack-in the pointer sits at the first position of the minibuffer until it resolves (it's been sitting there since I whined above about it)...
so I can't switch to another buffer, but I'm used to seeing the nrepl buffer at the end of a successful jack in.
I can C-g to get out of the cider-jack-in process, and just did, but there's no nrepl buffer open.
I'll hang up my spurs for the night. Too frustrating.
Thanks for taking a crack at it, though.
i recently spent some time figuring out why i could not open two project's cider repls at the same time. i found that the problem was in a mode that i loaded which bound the symbol `default to some value. this caused cider to fail, because it somewhere has a function which had an optional argument called 'default and expects it to be nil or a string. the global binding was a symbol, though.
i mean yes, no namespaces, how cute. but a global binding that overwrites the binding of a named function argument? i beg your f*ing pardon. </rant>
@macrobartfast What’s your CIDER version? What do you call the nrepl
buffer?
Here is where it causes the issue (seq-25.el): (cl-defgeneric seq-find (pred sequence &optional default)
I'm new to Emacs. Can anyone recommend a fuzzy file finder? I can't believe I have not found one yet.
@macrobartfast you can use clj-refactor to pull in deps into a running REPL. no need to restart. feature is called add-project-dependency. key combo is ap
Oh yeah, found what I was looking for. https://github.com/bling/fzf.el