clarify message on sbt.version mismatch

This commit is contained in:
Renato Cavalcanti 2019-12-19 08:21:28 +01:00
parent e4131814e7
commit 2f4b6f476a
No known key found for this signature in database
GPG Key ID: C7F92AA2BCB77E03
2 changed files with 3 additions and 3 deletions

View File

@ -827,8 +827,8 @@ object BuiltinCommands {
sbtVersionOpt.foreach( sbtVersionOpt.foreach(
version => version =>
if (version != app.id.version()) { if (version != app.id.version()) {
state.log.warn(s"""sbt version mismatch, current: ${app.id state.log.warn(s"""sbt version mismatch, using: ${app.id
.version()}, in build.properties: "$version", use 'reboot' to use the new value.""") .version()}, in build.properties: "$version".""")
} }
) )
} }

View File

@ -3,6 +3,6 @@ TaskKey[Unit]("checkSbtVersionWarning") := {
val logging = state.globalLogging val logging = state.globalLogging
val currVersion = state.configuration.provider.id.version() val currVersion = state.configuration.provider.id.version()
val contents = IO.read(logging.backing.file) val contents = IO.read(logging.backing.file)
assert(contents.contains(s"""sbt version mismatch, current: $currVersion, in build.properties: "1.1.1", use 'reboot' to use the new value.""")) assert(contents.contains(s"""sbt version mismatch, using: $currVersion, in build.properties: "1.1.1"."""))
() ()
} }