Fork me on GitHub
#cider
<
2017-10-13
>
achikin07:10:58

Hi, I'm looking at the inf-clojure and I have several questions about it. I've managed to set it up with my spacemacs config, but looking at the source code I can tell that it uses clojure-complete to provide completions from the repl. It seems to me that none of my projects have clojure-complete in their dependencies. Am I right that completions doesn't work for me with inf-clojure? I'm still getting some completions from somewhere so it's hard to tell if it works or not.

richiardiandrea16:10:24

@achikin inf-clojure targets the environment you are running in, so it should automatically get completions for Clojure REPL, Plank, Lumo

richiardiandrea16:10:30

If you don't see them there must be some detection problem and it is very likely the REPL is not yet supported

richiardiandrea16:10:40

What are you running against?

achikin16:10:30

@richiardiandrea I understand that. But in case of the "default" environment it tries to call complete.core/completions here https://github.com/clojure-emacs/inf-clojure/blob/master/inf-clojure.el#L794

richiardiandrea16:10:52

Yep that's right

achikin16:10:21

And when I'm trying to do that same call using that same running repl - it gives me an error

achikin16:10:30

I'm running standard nrepl

achikin16:10:38

against a clojure app

richiardiandrea16:10:58

So I would check if the namespace is on the classpath

achikin16:10:10

No, it's not.

richiardiandrea16:10:05

Ok ok so it's a documentation issue, I thought it was written somewhere that you need that (Dev) dependency for Clojure

achikin16:10:26

And the project clojure-complete seems abandoned https://github.com/ninjudd/clojure-complete

achikin16:10:05

As far as I can see from Cider - it uses nrepl internal completion, right?

dpsutton16:10:20

cider uses compliment

richiardiandrea16:10:30

Maybe we can change that btw, cider can import things btw as transitive deps

richiardiandrea16:10:11

So I would raise an issue asking to someone (maybe it will be me) to switch things to compliment

richiardiandrea16:10:12

In the meantime you can add the dependency and override inf-clojure-completions IIRC, in order to use implement instead

richiardiandrea16:10:46

It can get more sophisticated than that because compliment accepts a context and can complete locals..but one step at the time :))

achikin16:10:52

@richiardiandrea @dpsutton thank you very much for clarifying the situation and pointing me to the appropriate places in the source code.

dpsutton16:10:39

for sure. if you need a little intro on how to start messing with cider, checkout http://hackingcider.com. and if you put together some thoughts, add a PR and make an article to the site

achikin16:10:16

@dpsutton I have severe freezes using cider+figwheel, that's why I'm looking at the inf-clojure.

wpcarro18:10:12

Hey all. I’m looking to write a function that runs (require 'some-ns) for the current buffer, which is similar to cider-repl-set-ns, but should hopefully fetch the dependencies, etc… before I write this, I wanted to be sure that it doesn’t already exist and I’m missing it somehow

wpcarro18:10:45

Additionally — and not related — is I’m also looking for a CIDER variable that I can configure to always require the REPL-utils. Does this exist?

wpcarro18:10:58

I’m trying to avoid symbol lookup failures for things like (doc ...), (source ...), etc,