From 08091d64c1a158ce013ba792ff0d7c5a96981115 Mon Sep 17 00:00:00 2001 From: Ethan Atkins Date: Thu, 12 Dec 2019 19:34:04 -0800 Subject: [PATCH] Log server commands Prior to this change, if a network command came in, it would run in the background with no real feedback in the server ui. Prior to this change, running compile from the thin client would look like: sbt:scala-compile> [success] Total time: 1 s, completed Dec 12, 2019, 7:24:43 PM sbt:scala-compile> Now it looks like: sbt:scala-compile> [info] Running remote command: compile [success] Total time: 1 s, completed Dec 12, 2019, 7:26:17 PM sbt:scala-compile> --- main/src/main/scala/sbt/Main.scala | 3 +++ 1 file changed, 3 insertions(+) diff --git a/main/src/main/scala/sbt/Main.scala b/main/src/main/scala/sbt/Main.scala index 1f66e7d0e..463da05e7 100644 --- a/main/src/main/scala/sbt/Main.scala +++ b/main/src/main/scala/sbt/Main.scala @@ -900,6 +900,9 @@ object BuiltinCommands { .getOpt(Keys.minForcegcInterval) .getOrElse(GCUtil.defaultMinForcegcInterval) val exec: Exec = exchange.blockUntilNextExec(minGCInterval, s1.globalLogging.full) + if (exec.source.fold(true)(_.channelName != "console0")) { + s1.log.info(s"Running remote command: ${exec.commandLine}") + } val newState = s1 .copy( onFailure = Some(Exec(Shell, None)),