How can I get sbt to not "add anything extra" to println output?

Viewed 103

I have a utility that uses println. I want to do sbt 'runMain com.foo.bar.Main' and see only what I printlned: no [info] prefix on all the messages, and no front matter saying "welcome to sbt", "loading", etc. etc.

I'm looking to specify this option on the command line, as an argument to sbt, without changing anything in build.sbt. Is this possible?

1 Answers
sbt -batch -error 'runMain com.foo.bar.Main'

-batch tells sbt that you don't want to start any kind of interactive session, and -error limits all logging to errors only.

Related