[2.x] fix: Remove will-be-ignored warning (#9143)

**Problem**
run warns about jvm option not being applied,
but it is applied for client-side run.

**Solution**
Remove the warning.
This commit is contained in:
eugene yokota 2026-04-27 03:18:47 -04:00 committed by GitHub
parent 5b9553af9e
commit cd5fb7f7fb
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 0 additions and 32 deletions

View File

@ -2042,20 +2042,6 @@ object Defaults extends BuildCommon with DefExtra {
s.log.debug(s"javaOptions: $options")
new ForkRun(opts)
} else {
if (options.nonEmpty) {
val mask = ScopeMask(project = false)
val showJavaOptions = Scope.displayMasked(
(resolvedScope / javaOptions).scopedKey.scope,
(resolvedScope / javaOptions).key.label,
mask
)
val showFork = Scope.displayMasked(
(resolvedScope / fork).scopedKey.scope,
(resolvedScope / fork).key.label,
mask
)
s.log.warn(s"$showJavaOptions will be ignored, $showFork is set to false")
}
new Run(si, trap, tmp)
}
}

View File

@ -95,21 +95,6 @@ private[sbt] object ClassLoaders {
val s = streams.value
val opts = forkOptions.value
val options = javaOptions.value
if options.nonEmpty then
val mask = ScopeMask(project = false)
val showJavaOptions = Scope.displayMasked(
(resolvedScope / javaOptions).scopedKey.scope,
(resolvedScope / javaOptions).key.label,
mask
)
val showFork = Scope.displayMasked(
(resolvedScope / fork).scopedKey.scope,
(resolvedScope / fork).key.label,
mask
)
s.log.warn(s"$showJavaOptions will be ignored, $showFork is set to false")
val exclude = dependencyJars(exportedProducts).value
.map(converter.toPath)
.map(_.toFile)

View File

@ -44,9 +44,6 @@ object RunUtil:
val newFo = fo.withRunJVMOptions(fo.runJVMOptions ++ jvmArgs)
(new ForkRun(newFo), newFo)
case _ =>
log.warn(
s"JVM options (${jvmArgs.mkString(" ")}) will be ignored, fork is set to false"
)
(scalaRun, fo)
private def setWindowTitle(title: String): Unit =