title: How can I add war file to another java web application dependencies?
body: <p>I have web maven project. Project's output is a <code>war</code> file. I want to add this <code>war</code> file as dependency to project_b.<br>
  The project_b's <code>pom.xml</code> file, have a plugin as following:</p>
  
  <pre><code>...
  &lt;plugin&gt;
      &lt;inherited&gt;true&lt;/inherited&gt;
      &lt;groupId&gt;org.apache.maven.plugins&lt;/groupId&gt;
      &lt;artifactId&gt;maven-war-plugin&lt;/artifactId&gt;
      &lt;version&gt;2.3&lt;/version&gt;
      &lt;configuration&gt;
          &lt;warName&gt;geoserver&lt;/warName&gt;
          &lt;webappDirectory&gt;${project.build.directory}/geoserver&lt;/webappDirectory&gt;
          &lt;packagingExcludes&gt;WEB-INF/lib/servlet-api*.jar&lt;/packagingExcludes&gt;
          &lt;archive&gt;
              &lt;manifest&gt;
                  &lt;addDefaultImplementationEntries&gt;true&lt;/addDefaultImplementationEntries&gt;
                  &lt;addDefaultSpecificationEntries&gt;true&lt;/addDefaultSpecificationEntries&gt;
              &lt;/manifest&gt;
              &lt;manifestEntries&gt;
                  &lt;GeoServerModule&gt;core&lt;/GeoServerModule&gt;
                  &lt;Application-Name&gt;${project.build.finalname}&lt;/Application-Name&gt;
                  &lt;Project-Version&gt;${project.version}&lt;/Project-Version&gt;
                  &lt;Iteration-Name&gt;${iteration}&lt;/Iteration-Name&gt;
                  &lt;Build-Timestamp&gt;${maven.build.timestamp}&lt;/Build-Timestamp&gt;
                  &lt;Git-Revision&gt;${build.commit.id}&lt;/Git-Revision&gt;
              &lt;/manifestEntries&gt;
          &lt;/archive&gt;
      &lt;/configuration&gt;
      &lt;executions&gt;
          &lt;execution&gt;
              &lt;phase&gt;package&lt;/phase&gt;
              &lt;goals&gt;
                  &lt;goal&gt;war&lt;/goal&gt;
              &lt;/goals&gt;
          &lt;/execution&gt;
      &lt;/executions&gt;
  &lt;/plugin&gt;
  ...
  </code></pre>
  
  <p>How do I add the <code>war</code> of  web application to project_b with <code>&lt;groupId&gt;org.itsme&lt;/groupId&gt;</code>, <code>&lt;artifactId&gt;spring3-mvc-maven-xml-hello-world&lt;/artifactId&gt;</code>, <code>&lt;packaging&gt;war&lt;/packaging&gt;</code> and <code>&lt;version&gt;1.0-SNAPSHOT&lt;/version&gt;</code>?</p>