title: packagingExcludes doesn't work
body: <p>I'm working on a maven project and I need to exclude a dependency from my <code>war</code> file. Below are the details of my problem.</p>
  
  <p>I have a project <code>A</code> with <code>war</code> packaging that depend on</p>
  
  <pre><code>&lt;dependency&gt;
          &lt;groupId&gt;com.myCompany&lt;/groupId&gt;
          &lt;artifactId&gt;artifactB&lt;/artifactId&gt;
          &lt;version&gt;0.0.1-SNAPSHOT&lt;/version&gt;
  &lt;/dependency&gt;
  </code></pre>
  
  <p>I would like this project not to be present in final <code>war</code>. I can't use</p>
  
  <pre><code>&lt;scope&gt;provided&lt;/scope&gt;
  </code></pre>
  
  <p>because I need the transitive dependency of <code>artifactB</code>. I'm trying to exclude the <code>artifactB</code> during package phase with the following instruction:</p>
  
  <pre><code> &lt;packagingExcludes&gt;WEB-INF/lib/artifactB.jar&lt;/packagingExcludes&gt;
  </code></pre>
  
  <p>but when I run <code>mvn package</code>, I keep finding the <code>jar</code> inside my <code>war</code>. What am I doing wrong?</p>