Giter VIP home page Giter VIP logo

Comments (8)

arichiardi avatar arichiardi commented on September 28, 2024 1

It looks like the plugin does not know how to handle a vector of middleware symbols, which is what cider.nrepl/cider-middleware ends up being.

from clojure-maven-plugin.

arichiardi avatar arichiardi commented on September 28, 2024 1

Ok yes closing.

from clojure-maven-plugin.

danielsz avatar danielsz commented on September 28, 2024 1

@arichiardi 😊 ☺️ Awesome!

Yes, the README needs some love, for sure. I could do a PR after the weekend.

@talios In my opinion, not a problem, a README update is enough. Kind of interesting to contemplate the fact of authoring a wrapper to the Clojure compiler but then not using it much. Life is unpredictable, isn't it?! At any rate, thank you for your work, it's awesome. I have and still am benefiting from your efforts. πŸ™

from clojure-maven-plugin.

danielsz avatar danielsz commented on September 28, 2024

I was wondering: have you tried configuring the cider handler instead?

From the Cider manual:

(ns my-app
  (:require [nrepl.server :as nrepl-server]
            [cider.nrepl :refer (cider-nrepl-handler)]))

(defn -main
  []
  (nrepl-server/start-server :port 7888 :handler cider-nrepl-handler))

I suppose that translates to something like that:

<build>
          <plugins>
            <plugin>
              <groupId>com.theoryinpractise</groupId>
              <artifactId>clojure-maven-plugin</artifactId>
              <version>1.8.4</version>
              <extensions>true</extensions>
              <configuration>
                <nreplHandler>
                 cider.nrepl/cider-nrepl-handler
                </nreplHandler>
              </configuration>
            </plugin>
          </plugins>
        </build>

from clojure-maven-plugin.

danielsz avatar danielsz commented on September 28, 2024

Can we close this? I think the above is the recommended way forward with regards to Cider.

from clojure-maven-plugin.

danielsz avatar danielsz commented on September 28, 2024

Thanks, I feel like I should explain just a little bit more:

cider.nrepl/cider-middleware itself is not middleware. It is a vector that contains all Cider's middleware. It is a convenience used by Leiningen and Boot because it facilitates end-user configuration. In our case, we configure nREPL with the cider handler, which handles that for us:

(def cider-nrepl-handler
  "CIDER's nREPL handler."
  (apply nrepl-server/default-handler (map resolve-or-fail cider-middleware)))

Sorry if I rushed things a little bit. Maybe I shouldn't have.

from clojure-maven-plugin.

talios avatar talios commented on September 28, 2024

@danielsz so is this actually a problem? Or maybe something just needed a README update? ( I don't use nrepl or cider, or - actually actively use clojure beyond some libs our other teams use ).

from clojure-maven-plugin.

arichiardi avatar arichiardi commented on September 28, 2024

No problem @danielsz! You did not rush it πŸ˜„

For sure it is something we can add to the README, because it kind of gives different directions compared to what the current cider manual gives. It is also a newer addition to the cider.nrepl namespace and indeed quite convenient 😸

from clojure-maven-plugin.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.