Avoiding depenedency resolving for multiple subprojects

14 views
Skip to first unread message

Serhii Nesteruk

unread,
Oct 12, 2012, 4:48:24 AM10/12/12
to simple-b...@googlegroups.com
Hi,

There are few subprojects in my sbt configuration that shares the same libraries:
    
    object myApp extends Build {

      lazy val projectA
= Project(id = "projectA", {
      settings
= Project.defaultSettings + commonSettings
     
})

     lazy val projectB
= Project(id = "projectB",{
      settings
= Project.defaultSettings + commonSettings
     
}) dependsOn (projectA)

     lazy val projectC
= Project(id = "projectC"){
      settings
= Project.defaultSettings + commonSettings
     
}) dependsOn (projectB)

     val commonSettings
= Seq(
     libraryDependencies
++= dependencies
     
)


     val dependencies
= Seq(
     
"junit" % "junit" % "4.10",
     
.... more 50 artifacts
     
)
    }

Actually dependency resolving works fine and the project build is success. The issue is that sbt resolve dependency for each project independent. There are a lot of subprojects and artifacts and it is really annoying and takes a lot of time to complete build.

Is it possible to avoid dependency resolving for each subproject?
Reply all
Reply to author
Forward
0 new messages