ring/compojure without jetty

I know it's possible to create a war file using lein ring war , but it seems to still include jetty dependencies. Is there a way to exclude the jetty dependencies when I'm building the war (and deploying on tomcat)?

If I can't does this matter at all or is it just extra jars/class files that are packaged up into the war but never actually used?


Leinigen supports :exclusions in a dependency.

(defproject my-project "1.0.0"
     :dependencies [[org.clojure/clojure "1.2.0"]
                    [org.clojure/clojure-contrib "1.2.0"]]
     :dev-dependencies [[autodoc "0.7.1" :exclusions [org.apache.ant/ant]]])

See here for details.

Often the problem is working out where the dependencies are coming from. In maven you can do this:

mvn dependency:tree 

to get a useful ASCII art representation of the dependency tree.

One option would be to generate a pom.xml for your project using

lein pom

Then runing maven over that.

链接地址: http://www.djcxy.com/p/56978.html

上一篇: lein ring uberwar NullPointerException

下一篇: 环/组合没有码头