title: Heroku Spring Boot doesn't build Jar
body: <p>I am deploying to Heroku, I haven't really changed anything yet now Heroku is not creating the Jar.</p>
  
  <p>Gradle buildpack is still in "beta" though it hasn't ever failed me.</p>
  
  <p>Heroku</p>
  
  <pre><code>remote: -----&gt; Using set buildpack heroku/gradle
  remote: -----&gt; Gradle app detected
  remote: -----&gt; Installing OpenJDK 1.8... done
  remote: -----&gt; Installing Gradle Wrapper...
  remote:        WARNING: Your application does not have it's own gradlew file.
  remote:        We'll install one for you, but this is a deprecated feature and
  remote:        in the future may not be supported.
  remote: -----&gt; Building Gradle app...
  remote:        WARNING: The Gradle buildpack is currently in Beta.
  remote: -----&gt; executing ./gradlew stage
  remote:        :api:compileJavaNote: Some input files use unchecked or unsafe operations.
  remote:        Note: Recompile with -Xlint:unchecked for details.
  remote:        
  remote:        :api:processResources
  remote:        :api:classes
  remote:        :api:war
  remote:        :api:bootRepackage
  remote:        :api:assemble
  remote:        :api:cleanNode
  remote:        :api:stage
  remote:        BUILD SUCCESSFUL
  </code></pre>
  
  <p>Notice the lack of <code>:api:jar</code> and yet locally it is there..</p>
  
  <pre><code>:api:compileJava UP-TO-DATE
  :api:processResources UP-TO-DATE
  :api:classes UP-TO-DATE
  :api:jar
  :api:findMainClass
  :api:startScripts
  :api:distTar
  :api:distZip
  :api:war
  :api:bootRepackage
  :api:assemble
  :api:cleanNode
  :api:stage
  
  BUILD SUCCESSFUL
  </code></pre>
  
  <p>And the Gradle is straight forward.</p>
  
  <pre><code>apply plugin: "java"
  apply plugin: "war"
  apply plugin: "spring-boot"
  
  task cleanNode {
      doLast {
          // clean up files we no longer need in the slug
          delete '../node_modules'
          delete '../html/bower_components'
      }
  }
  
  // used by Heroku
  task stage {
      dependsOn cleanNode, assemble
  }
  </code></pre>