title: Create a ZIP archive with Maven
body: <p>I followed the answer for how to create a ZIP archive in Maven here: <a href="https://stackoverflow.com/a/2514677/1395165">https://stackoverflow.com/a/2514677/1395165</a> 
  and have a couple of follow-up questions:</p>
  
  <p><strong>ZIP contents to exclude directory:</strong></p>
  
  <p>As in the example I have:</p>
  
  <pre><code>&lt;fileSet&gt;
      &lt;directory&gt;${project.basedir}/src/export&lt;/directory&gt;
      &lt;useDefaultExcludes&gt;true&lt;/useDefaultExcludes&gt;
  &lt;/fileSet&gt;
  </code></pre>
  
  <p>In the ZIP I get </p>
  
  <pre><code>src
    export
       Dir1
       Dir2
  </code></pre>
  
  <p>but I only want to have </p>
  
  <pre><code>Dir1
  Dir2 
  </code></pre>
  
  <p>in the ZIP. Is that possible?</p>
  
  <p><strong>Output file name</strong></p>
  
  <p>The output file name is created with a .zip extension. Is it possible in Maven to override the extension to something else (say .abc)?</p>