title: Gradle Multiproject Build pushToLocalMaven before
body: <p>I have a gradle project consist of multiple java projects. Let's say we have two projects, ProjectA and ProjectB. I would like to send ProjectA jar to local maven repo, before ProjectB starts to compile. Because ProjectB depends on ProjectA. I know I can do this from command line with <code>gradle clean build pTML</code> or <code>gradle publishToMavenLocal</code> command separately. But, I want to do this in main build.gradle without any extra steps in one shot.  </p>
  
  <pre><code>RootProject
  ├── ProjectA
  │   ├── build.gradle
  │   └── src
  └── ProjectB
      ├── build.gradle
      └── src
  </code></pre>