ivy

How does ivy:publish work?

烈酒焚心 提交于 2019-12-02 18:05:31
I'm completely at loss how the ant task ivy:publish is supposed to work. I would expect that I do my normal build, which creates a bunch of jar files, then I would push those jars to the (local) repository. How can I specify from where to retrieve the built jars, and how would those end up in the repository? Update: <target name="publish-local" description="--> Publish Local"> <ivy:retrieve /> <ivy:publish resolver="local" pubrevision="${release.version}" status="release" update="true" overwrite="true"> <artifacts pattern="${dist.dir}/[organisation]-[module].[ext]" /> </ivy:publish> </target>

Ivy via Nexus proxy

霸气de小男生 提交于 2019-12-02 17:44:21
does anyone knows how do I specify in Ivy something like mirror/mirrorOf in Maven? I'm working with a local Maven proxy (Nexus) and need the tool to specify which of the parent repositories should Nexus proxy be accessing. In Maven I do simply: <mirrors> <mirror> <id>central-mirror</id> <mirrorOf>central</mirrorOf> <url>http://localhost:8081/content/repositories/central</url> </mirror> </mirrors> but I can't find this kind of option in Ivy. I don't think such an option exists directly. You could try implementing a chain , and put your Nexus repository ahead of central in that chain. If I

Use maven repository as local ivy cache

↘锁芯ラ 提交于 2019-12-02 17:07:39
Is there any possibility to use local Maven repository (~/.m2) as local Ivy cache (~/.ivy)? They have different layouts. Sometimes I use Maven and sometimes I use SBT which uses Ivy underneath, so I have 2 copies of same libs in both Maven and Ivy. I would like to use same dir thus saving disk space and network. Thanks. You can specify the cache and the layout of the cache by using the <cache/> Tag . I think you will have to alter the patterns for the artifacts/ivy.xml files. The Tag is described here: http://ant.apache.org/ivy/history/2.0.0/settings/caches.html . It seems that it should work,

Maven or Ivy for Managing Dependencies from Ant?

时光怂恿深爱的人放手 提交于 2019-12-02 16:36:44
I was wondering about the best way to manage projects dependencies from ant. What are the pros and cons of the Maven Ant task and of Ivy? Chris Since what you're wanting to do is add dependency management to an existing Ant project, that's precisely what Ivy's designed to do. Dependency management is a big part of Maven, but far from all of it. Maven is more of a project-oriented tool that does several other things in addition to dependencies. It would be worth considering if you were planning to migrate to Maven and use additional Maven features as well, but it's a bit much if all you'd use

sbt: publish to corporate Nexus repository unauthorized

非 Y 不嫁゛ 提交于 2019-12-02 16:19:58
Quick resolution The required credential expects the exact realm as defined by nexus. See below how to find the one you have defined, but most certainly is "Sonatype Nexus Repository Manager". Add the rest of the details to the credentials as normal. c:/data/user/.sbt/.credentials realm=Sonatype Nexus Repository Manager host=nexus user=repouser password=password build.sbt credentials += Credentials(Path.userHome / ".sbt" / ".credentials") publishTo <<= version { v: String => val nexus = "http://nexus/" if (v.trim.endsWith("SNAPSHOT")) Some("snapshots" at nexus + "content/repositories/libs

How can I use an Ant taskdef that depends on lib imported by ivy

只愿长相守 提交于 2019-12-02 13:01:39
问题 I've created a taskdef in my build.xml that depends on a class that resides in a jar imported by Ivy. I'd like to understand if it's possible in any way, given the fact that my build breaks before starting because it can't find the class for the taskdef. This seems a egg and chicken issue, as I can't get the class because I'd have to resolve my dependencies first (which needs the build to be working). 回答1: Yes, it is possible. However, it means that you must resolve and retrieve the jars

Ivy can not resolve the scope of a dependency which is a dependency of a transitive dependency

老子叫甜甜 提交于 2019-12-02 12:05:34
问题 I add a dependency(let's name it as A) to ivy.xml which has a pom file in maven central. Ivy uses ibiblio for resolving the maven dependencies. The dependency(A) which is added to ivy.xml has a transitive dependency(B). So far so good till here. The dependency(C) of transitive dependency(B) can not be resolved by ivy. I defined A in ivy.xml like this: <dependency org="Z" name="A" rev="0.6-SNAPSHOT" conf="*->default"/> In pom file of B, C is defined both in compile and test scopes like below:

Online dependence not found in .ivy2 file and not found by Intellij Idea

微笑、不失礼 提交于 2019-12-02 10:56:02
问题 I have an IntelliJ Idea project that uses external libraries. I cannot find one of this libraries in the ~/.ivy2/cache directory. The sbt file looks like: name := "myproject" scalaVersion := "2.11.8" lazy val toImport = RootProject(uri("someuri#hash")) lazy val root = (project in file(".")).dependsOn(toImport) IntelliJ Idea underlines the toImport line saying that it cannot find it. How can I solve this? 回答1: If you mean the RootProject is highlighted red, it seem you've run into a problem

In Grails, how do I specify jars needed by an ivy resolver?

笑着哭i 提交于 2019-12-02 09:39:43
问题 In a grails project I have added a custom ivy resolver per the reference docs, http://www.grails.org/doc/latest/guide/single.html#12.2%20Plugin%20Repositories . However, this resolver requires jsch and and some other jars. How can I put them on the project's build classpath so that ivy will use them? This is my BuildConfig.groovy grails.project.class.dir = "target/classes" grails.project.test.class.dir = "target/test-classes" grails.project.test.reports.dir = "target/test-reports" grails

<ivy:cachepath> is SLOW, how to avoid doing it every build and improve ivy cachepath performance?

耗尽温柔 提交于 2019-12-02 09:20:36
Compile times are slowed by 4s resolving dependant libs for my javac step every build on this line: <target name="compile" depends="bootstrap"> <ivy:cachepath pathid="classpath"/> <!-- SLOW --> I want to essentially CACHE the results of ivy:cachepath so I don't have to do it every build. I want ${classpath} to exist in less than 0.2 seconds Context: This is a vanilla ant build.xml which bootstraps ivy, uses an ivy.xml file that lists standard maven dependencies, then calls javac with those libs in a class path) <property name="ivy.install.version" value="2.4.0"/> <property name="ivy.jar.dir"