I want to translate a Maven dependency to Leiningen:
<dependency>
<groupId>com.google.api.client</groupId>
<artifactId>google-api-client-parent</artifactId>
<version>1.4.1-beta</version>
</dependency>
I tried:
(defproject gdata2 "1.0.0-SNAPSHOT"
:description "FIXME: write"
:dependencies [[org.clojure/clojure "1.2.0"]
[org.clojure/clojure-contrib "1.2.0"]
[com.google.api.client/google-api-client-parent "1.4.1-beta"]])
However this doesn't work since there is no jar in the Maven central repository, just a parent pom. Leiningen tries to find google-api-client-parent-1.4.1-beta.jar and fails.
How do I tell Leiningen to just look at the pom and resolve the transitive dependencies?
Edit May 12
It seems that the code I need is not in the standard Maven repositories. I have to add the Leiningen equivalent of:
<repository>
<id>google-api-services</id>
<url>http://mavenrepo.google-开发者_StackOverflowapi-java-client.googlecode.com/hg</url>
</repository>
And add google-api-services-tasks-1.0.0-beta.jar to the dependencies and then it is probably going to work. Will check and close this question when back from work :)
That POM project doesn't define any dependency, just a dependencyManagement
section. You probably want to depend on real libraries (e.g. JARs), which will in turn pull the whole dependency tree into the picture while solving your problem.
精彩评论