Closed jeantil closed 10 years ago
I have found an easy enough workaround for anyone who wants to use a grunt key before 0.6.3
I wanted to deploy to heroku which uses the stage task to package up the application, I could not easily override the task used (implies creating and using a custom build pack which is not as simple as it sounds, and more importantly implies remembering to set the custom build pack for each new platform etc) instead here is what I did :
// defined a key
lazy val mygrunt =taskKey[Any]("run grunt")
// used it in my settings
val appSettings: Seq[sbt.Setting[_]] =
play.Project.playScalaSettings ++
com.tuplejump.sbt.yeoman.Yeoman.yeomanSettings ++
Seq(
libraryDependencies ++= buildDependencies
, resolvers := Repositories.resolvers
, mygrunt in ThisBuild := {
val s: TaskStreams = streams.value
s.log.info(yeomanGruntfile.value)
Process(s"grunt --gruntfile=${yeomanGruntfile.value}", yeomanDirectory.value) ! (s.log)
}
, stage <<= stage.dependsOn(mygrunt)
) ++
Format.settings
By making stage depend on mygrunt, grunt is automatically executed before the stage task. This did not help with heroku though since grunt isn't available when running on heroku :(
Will try and restart snapshot publishing from 0.6.4-Snapshot as that development starts.
Hello,
It seems snapshot publication stopped at 0.2.1 (https://oss.sonatype.org/content/repositories/snapshots/com/tuplejump/) which is sad because I would like to give 0.6.3 a try (I need the grunt key :) )