SBT Console: sbt test shows no color

When executing SBT tests in SBT Console, the test is not showing any color. 

But when I run the tests in my Terminal the tests are colored

 

How can i enable colors in my SBT console tab in IntelliJ so taht I can spot test failures easily?

 

3
5 comments

They should not be disabled by default. Can you check your SBT vm parameters if you are adding the -Dsbt.log.noformat option there?

 

0
Avatar
Permanently deleted user

I can't see colors either and the -Dsbt.log.noformat option isn't there. I'm using Windows 10 and IntelliJ 2017.2.4, in case that's any help

0

Same for me. No colors in the sbt-shell.

IntelliJ IDEA 2020.2.3 (Community Edition)
Build #IC-202.7660.26, built on October 6, 2020
Runtime version: 11.0.8+10-b944.34 amd64
VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o.
Windows 10 10.0
GC: ParNew, ConcurrentMarkSweep
Memory: 1970M
Cores: 12
Registry: ide.balloon.shadow.size=0
Non-Bundled Plugins: org.jetbrains.plugins.hocon, Docker, com.atlassian.bitbucket.references, ru.adelf.idea.dotenv, some.awesome, org.intellij.scala, org.jetbrains.kotlin

Would be a super nice addition !

0

I have the same issue on Windows, with Scala Plugin 2021.2.24 on IntelliJ 2021.2.2.

Even though there's no -Dsbt.log.noformat option in the SBT vm parameters. I've found that when in the command shown in the sbt console, there is always a "-Dsbt.log.noformat=true" option set. And I don't know where it comes from:

 

"C:\Program Files\Eclipse Foundation\jdk-17.0.0.35-hotspot\bin\java.exe" -server -Xmx1536M -Dsbt.supershell=false -Dsbt.server.forcestart=true -Didea.managed=true -Didea.installation.dir=C:\Users\xxx\AppData\Local\JetBrains\Toolbox\apps\IDEA-U\ch-0\212.5284.40 -Dsbt.log.noformat=true -jar C:\Users\xxx\AppData\Local\JetBrains\Toolbox\apps\IDEA-U\ch-0\212.5284.40.plugins\Scala\launcher\sbt-launch.jar early(addPluginSbtFile=\"\"\"C:\Users\xxx\AppData\Local\Temp\idea.sbt\"\"\") "; set ideaPort in Global := 1389 ; idea-shell"

 

Could you please help to take a look?

 

------------

IntelliJ IDEA 2021.2.2 (Ultimate Edition)
Build #IU-212.5284.40, built on September 14, 2021
Runtime version: 11.0.12+7-b1504.28 amd64
VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o.
Windows 10 10.0
GC: G1 Young Generation, G1 Old Generation
Memory: 5000M
Cores: 12

0

it turns out this should be reason why the option is set this way:

https://github.com/JetBrains/intellij-scala/blob/bce780a19af9ac6ff42522c625d6dac1a52cecd7/scala/scala-impl/src/org/jetbrains/sbt/shell/SbtProcessManager.scala#L151

if(SystemInfo.isWindows)

  vmParams.add("-Dsbt.log.noformat=true")

0

Please sign in to leave a comment.