So, as the title suggests, can sbtresolve .pom files dependencies that contain only configurations/properties and have no .jar file associated?
Im currently developing a new frontend app using Play! Framework and angularjs. Here's the scenario:
Root Project (à la maven compilation/deploy)
- Core business Module - pom.xml
Web modules - pom.xml
- Rest API-pom.xml
- Module - pom.xml
- Module - pom.xml
Frontend (à la SBT compilation, multi-module project)
- Mod1 - build.sbt
- Mod2 - build.sbt (depends on mod1)
- More modules inside - build.sbt
build.sbt
project/build.scala
- Rest API-pom.xml
- Web Commons (used on the Rest API and Frontend) - pom.xml
The sbt compilation is ran via maven using a plugin, sbt-launcher if im not mistaken. Everything runs and compiles as expected, however, we ran into a problem when we added WebCommons as a dependency in the frontend's build.sbt file. The problem relys on the fact that, the root's pom.xml has a parent of his own, lets call it X, and X contains several .pom files that delegate to child modules (in this case the root project) config/properties/dependencies that are necessary to ease RPM packaging. Running maven clean install, the compilation process goes perfectly fine, we reach the frontend and the sbt compilation cycle starts as expected. When sbt tries to resolve the web-commons dependency, it also resolves every parent. In this case, web-commons->web-modules->root->X. When he reaches X, finds that there are several dependencies with him (not relevant at all for the frontend...) but these are made of .pom files not jar's. These .pom files are downloaded correctly using resolvers but then, sbt searches for the corresponding .jar files taking an enormous time to finish the build, and when it does, errors, errors everywhere (missing dependencies). I've tried several possible solutions:
1.intransitive() in web-commons dependency, not effective, still trying to find parents dep.
2.exclude(organization,filename*), again not effective.
3.excludeAll( ExclusionRule(org,dep1) ExclusionRule(org,dep2) ... ), sadly, not effective.
Im currently using sbt 0.13.2/6 (tried both). My next step was to define an ivy.xml and ivysettings.xml that configures this dependency and force the type=pom. Might this work? Any other sugestion/workaround?
Thanks in advance.