title: How to stop Maven from unpacking on every Project Run
body: <p>I have a JavaFX project that uses Hibernate ORM and has Maven. Each time when i Run my project i have to wait ages for it to run because Maven keeps unpacking Hibernate dependencies. Is this essential? Or can i turn it off, why would have to unpack everything over and over again instead of just once? The log looks like this:</p>
  
  <blockquote>
    <p>--- maven-dependency-plugin:2.6:unpack-dependencies (unpack-dependencies) @ SeedCalendar ---
    Unpacking C:\Users\maurice.m2\repository\org\hibernate\javax\persistence\hibernate-jpa-2.1-api\1.0.0.Final\hibernate-jpa-2.1-api-1.0.0.Final.jar to C:\book\SeedCalendar\target\classes with includes "" and excludes ""
    Unpacking C:\Users\maurice.m2\repository\org\hibernate\hibernate-core\5.2.9.Final\hibernate-core-5.2.9.Final.jar to C:\book\SeedCalendar\target\classes with includes "" and excludes ""
    Unpacking C:\Users\maurice.m2\repository\org\javassist\javassist\3.20.0-GA\javassist-3.20.0-GA.jar to C:\book\SeedCalendar\target\classes with includes "" and excludes ""
    Unpacking C:\Users\maurice.m2\repository\antlr\antlr\2.7.7\antlr-2.7.7.jar to C:\book\SeedCalendar\target\classes with includes "" and excludes ""
    Unpacking C:\Users\maurice.m2\repository\com\fasterxml\classmate\1.3.0\classmate-1.3.0.jar to C:\book\SeedCalendar\target\classes with includes "" and excludes ""
    Unpacking C:\Users\maurice.m2\repository\dom4j\dom4j\1.6.1\dom4j-1.6.1.jar to C:\book\SeedCalendar\target\classes with includes "" and excludes ""
    Unpacking C:\Users\maurice.m2\repository\org\jboss\jandex\2.0.3.Final\jandex-2.0.3.Final.jar to C:\book\SeedCalendar\target\classes with includes "" and excludes ""
    Unpacking C:\Users\maurice.m2\repository\org\jboss\logging\jboss-logging\3.3.0.Final\jboss-logging-3.3.0.Final.jar to C:\book\SeedCalendar\target\classes with includes "" and excludes ""
    Unpacking C:\Users\maurice.m2\repository\org\jboss\spec\javax\transaction\jboss-transaction-api_1.2_spec\1.0.1.Final\jboss-transaction-api_1.2_spec-1.0.1.Final.jar to C:\book\SeedCalendar\target\classes with includes "" and excludes ""
    Unpacking C:\Users\maurice.m2\repository\org\hibernate\common\hibernate-commons-annotations\5.0.1.Final\hibernate-commons-annotations-5.0.1.Final.jar to C:\book\SeedCalendar\target\classes with includes "" and excludes ""
    --- exec-maven-plugin:1.2.1:exec (unpack-dependencies) @ SeedCalendar ---
    javafxpackager.exe has been renamed javapackager.exe.
    The original file may be removed in a future release in lieu of javapackager.
    Please update your scripts.</p>
  </blockquote>
  
  <p>My POMfile looks like this:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
   &lt;project xmlns="http://maven.apache.org/POM/4.0.0"     xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0   http://maven.apache.org/xsd/maven-4.0.0.xsd"&gt;
  &lt;modelVersion&gt;4.0.0&lt;/modelVersion&gt;
  
  &lt;groupId&gt;com.hibernate&lt;/groupId&gt;
  &lt;artifactId&gt;SeedCalendar&lt;/artifactId&gt;
  &lt;version&gt;1.0-SNAPSHOT&lt;/version&gt;
  &lt;packaging&gt;jar&lt;/packaging&gt;
  
  &lt;name&gt;SeedCalendar&lt;/name&gt;
  
  &lt;properties&gt;
      &lt;project.build.sourceEncoding&gt;UTF-8&lt;/project.build.sourceEncoding&gt;
      &lt;mainClass&gt;com.hibernate.seedcalendar.MainApp&lt;/mainClass&gt;
  &lt;/properties&gt;
  
  &lt;organization&gt;
      &lt;!-- Used as the 'Vendor' for JNLP generation --&gt;
      &lt;name&gt;Your Organisation&lt;/name&gt;
  &lt;/organization&gt;
  
  &lt;build&gt;
      &lt;plugins&gt;
          &lt;plugin&gt;
              &lt;groupId&gt;org.apache.maven.plugins&lt;/groupId&gt;
              &lt;artifactId&gt;maven-dependency-plugin&lt;/artifactId&gt;
              &lt;version&gt;2.6&lt;/version&gt;
              &lt;executions&gt;
                  &lt;execution&gt;
                      &lt;id&gt;unpack-dependencies&lt;/id&gt;
                      &lt;phase&gt;package&lt;/phase&gt;
                      &lt;goals&gt;
                          &lt;goal&gt;unpack-dependencies&lt;/goal&gt;
                      &lt;/goals&gt;
                      &lt;configuration&gt;
                          &lt;excludeScope&gt;system&lt;/excludeScope&gt;
                          &lt;excludeGroupIds&gt;junit,org.mockito,org.hamcrest&lt;/excludeGroupIds&gt;
                          &lt;outputDirectory&gt;${project.build.directory}/classes&lt;/outputDirectory&gt;
                      &lt;/configuration&gt;
                  &lt;/execution&gt;
              &lt;/executions&gt;
          &lt;/plugin&gt;
           &lt;plugin&gt;
              &lt;groupId&gt;org.codehaus.mojo&lt;/groupId&gt;
              &lt;artifactId&gt;exec-maven-plugin&lt;/artifactId&gt;
              &lt;version&gt;1.2.1&lt;/version&gt;
              &lt;executions&gt;
                  &lt;execution&gt;
                      &lt;id&gt;unpack-dependencies&lt;/id&gt;
  
                      &lt;phase&gt;package&lt;/phase&gt;
                      &lt;goals&gt;
                          &lt;goal&gt;exec&lt;/goal&gt;
                      &lt;/goals&gt;
                      &lt;configuration&gt;
                          &lt;executable&gt;${java.home}/../bin/javafxpackager&lt;/executable&gt;
                          &lt;arguments&gt;
                              &lt;argument&gt;-createjar&lt;/argument&gt;
                              &lt;argument&gt;-nocss2bin&lt;/argument&gt;
                              &lt;argument&gt;-appclass&lt;/argument&gt;
                              &lt;argument&gt;${mainClass}&lt;/argument&gt;
                              &lt;argument&gt;-srcdir&lt;/argument&gt;
                              &lt;argument&gt;${project.build.directory}/classes&lt;/argument&gt;
                              &lt;argument&gt;-outdir&lt;/argument&gt;
                              &lt;argument&gt;${project.build.directory}&lt;/argument&gt;
                              &lt;argument&gt;-outfile&lt;/argument&gt;
                              &lt;argument&gt;${project.build.finalName}.jar&lt;/argument&gt;
                          &lt;/arguments&gt;
                      &lt;/configuration&gt;
                  &lt;/execution&gt;
                  &lt;execution&gt;
                      &lt;id&gt;default-cli&lt;/id&gt;
                      &lt;goals&gt;
                          &lt;goal&gt;exec&lt;/goal&gt;                            
                      &lt;/goals&gt;
                      &lt;configuration&gt;
                          &lt;executable&gt;${java.home}/bin/java&lt;/executable&gt;
                          &lt;commandlineArgs&gt;${runfx.args}&lt;/commandlineArgs&gt;
                      &lt;/configuration&gt;
                  &lt;/execution&gt;
              &lt;/executions&gt;  
          &lt;/plugin&gt;           
          &lt;plugin&gt;
              &lt;groupId&gt;org.apache.maven.plugins&lt;/groupId&gt;
              &lt;artifactId&gt;maven-compiler-plugin&lt;/artifactId&gt;
              &lt;version&gt;3.1&lt;/version&gt;
              &lt;configuration&gt;
                  &lt;source&gt;1.7&lt;/source&gt;
                  &lt;target&gt;1.7&lt;/target&gt;
                  &lt;compilerArguments&gt;
                      &lt;bootclasspath&gt;${sun.boot.class.path}${path.separator}${java.home}/lib/jfxrt.jar&lt;/bootclasspath&gt;
                  &lt;/compilerArguments&gt;
              &lt;/configuration&gt;
          &lt;/plugin&gt;
          &lt;plugin&gt;
              &lt;groupId&gt;org.apache.maven.plugins&lt;/groupId&gt;
              &lt;artifactId&gt;maven-surefire-plugin&lt;/artifactId&gt;
              &lt;version&gt;2.16&lt;/version&gt;
              &lt;configuration&gt;
                  &lt;additionalClasspathElements&gt;
                      &lt;additionalClasspathElement&gt;${java.home}/lib/jfxrt.jar&lt;/additionalClasspathElement&gt;
                  &lt;/additionalClasspathElements&gt;
              &lt;/configuration&gt;
          &lt;/plugin&gt;
      &lt;/plugins&gt;
  &lt;/build&gt;
  
  &lt;dependencies&gt;
  &lt;dependency&gt;
  &lt;groupId&gt;org.hibernate&lt;/groupId&gt;
  &lt;artifactId&gt;hibernate-core&lt;/artifactId&gt;
  &lt;version&gt;5.2.9.Final&lt;/version&gt;
  </code></pre>
  
  <p>
      </p>
  
  <p></p>
  
  <p>Can anyone tell me step by step how to turn this annoying feature off and if there will be any bad repercussions when turning this auto-unpack mode off?</p>
  
  <p>thank you!</p>