Skip to content

Commit aa02ef4

Browse files
committed
Merge pull request julienba#14 from Amadeus82/master
Compatibility for Play 2.2.x
2 parents 38adb21 + b8ca7d0 commit aa02ef4

File tree

6 files changed

+12
-11
lines changed

6 files changed

+12
-11
lines changed

build.sbt

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,13 @@ sbtPlugin := true
44

55
name := "play2-plugins-mustache"
66

7-
version := "1.1.3-SNAPSHOT"
7+
version := "1.1.3"
88

99
organization := "org.jba"
1010

11-
addSbtPlugin("play" % "sbt-plugin" % "2.1.0")
11+
scalacOptions += "-deprecation"
12+
13+
addSbtPlugin("com.typesafe.play" % "sbt-plugin" % "2.2.0")
1214

1315
libraryDependencies += "commons-lang" % "commons-lang" % "2.6"
1416

@@ -22,4 +24,3 @@ publishTo <<= (version) { version: String =>
2224
val localRepository = Resolver.file("local repo", new java.io.File(System.getProperty("user.home") + "/tmp/repo"))(Resolver.ivyStylePatterns)
2325
Some(localRepository)
2426
}
25-

project-code/project/Build.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ object ApplicationBuild extends Build {
66

77
val appName = "play2-mustache"
88

9-
val appVersion = "1.1.2"
9+
val appVersion = "1.1.3"
1010

1111
val appDependencies = Seq(
1212
"com.github.spullara.mustache.java" % "compiler" % "0.8.11",
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
sbt.version=0.12.2
1+
sbt.version=0.13.0

project-code/project/plugins.sbt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@ logLevel := Level.Warn
55
resolvers += "Typesafe repository" at "http://repo.typesafe.com/typesafe/releases/"
66

77
// Use the Play sbt plugin for Play projects
8-
addSbtPlugin("play" % "sbt-plugin" % Option(System.getProperty("play.version")).getOrElse("2.0.4") )
8+
addSbtPlugin("com.typesafe.play" % "sbt-plugin" % Option(System.getProperty("play.version")).getOrElse("2.0.4") )

project/build.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
sbt.version=0.12.2
1+
sbt.version=0.13.0

src/main/scala/org/jba/SbtMustachePlugin.scala

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ object MustachePlugin extends sbt.Plugin {
1414

1515
val templates = scala.collection.mutable.Map.empty[String, String]
1616

17-
lazy val mustacheTemplatesSettings: Seq[Project.Setting[_]] = Seq()
17+
lazy val mustacheTemplatesSettings: Seq[Def.Setting[_]] = Seq()
1818

1919
val MustacheFileCompiler = MyAssetsCompiler(
2020
"mustache",
@@ -48,11 +48,11 @@ object MustachePlugin extends sbt.Plugin {
4848
naming: (String, Boolean) => String,
4949
compile: (File, Seq[String]) => (String, Option[String], Seq[File]),
5050
optionsSettings: sbt.SettingKey[Seq[String]]) =
51-
(sourceDirectory in Compile, resourceManaged in Compile, cacheDirectory, optionsSettings, filesSetting, classDirectory in Compile) map { (src, resources, cache, options, files, classDirectory) =>
51+
(sourceDirectory in Compile, resourceManaged in Compile, streams in Compile, optionsSettings, filesSetting, classDirectory in Compile) map { (src, resources, streams, options, files, classDirectory) =>
5252

5353
import java.io._
5454

55-
val cacheFile = cache / name
55+
val cacheFile = streams.cacheDirectory / name
5656
val currentInfos = watch(src).get.map(f => f -> FileInfo.lastModified(f)).toMap
5757
val (previousRelation, previousInfo) = Sync.readInfo(cacheFile)(FileInfo.lastModified.format)
5858

@@ -99,7 +99,7 @@ object MustachePlugin extends sbt.Plugin {
9999

100100
}
101101

102-
}: sbt.Project.Initialize[sbt.Task[Seq[java.io.File]]]
102+
}: sbt.Def.Initialize[sbt.Task[Seq[java.io.File]]]
103103

104104
/**
105105
* Generate something like that:

0 commit comments

Comments
 (0)