diff options
author | Som Snytt <som.snytt@gmail.com> | 2015-06-22 20:56:40 -0700 |
---|---|---|
committer | Som Snytt <som.snytt@gmail.com> | 2015-06-23 15:52:01 -0700 |
commit | 934a31488b43b75a5b437e0cb293b6b5b4f076d7 (patch) | |
tree | 0e5e85a6125fb56eff158b633495f643a4abc200 /src/repl/scala/tools/nsc/interpreter/IMain.scala | |
parent | 1b9cb466430b6300355185917257493ca2e6a240 (diff) | |
download | scala-934a31488b43b75a5b437e0cb293b6b5b4f076d7.tar.gz scala-934a31488b43b75a5b437e0cb293b6b5b4f076d7.tar.bz2 scala-934a31488b43b75a5b437e0cb293b6b5b4f076d7.zip |
SI-9206: REPL custom welcome message
Can be specified by `-Dscala.repl.welcome=Greeting` or in properties
file. It takes the same format arguments as the prompt, viz, version,
Java version and JVM name.
It can be disabled by `-Dscala.repl.welcome` with no text.
Diffstat (limited to 'src/repl/scala/tools/nsc/interpreter/IMain.scala')
-rw-r--r-- | src/repl/scala/tools/nsc/interpreter/IMain.scala | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/src/repl/scala/tools/nsc/interpreter/IMain.scala b/src/repl/scala/tools/nsc/interpreter/IMain.scala index 2550a5dc57..841b4abfa5 100644 --- a/src/repl/scala/tools/nsc/interpreter/IMain.scala +++ b/src/repl/scala/tools/nsc/interpreter/IMain.scala @@ -113,9 +113,7 @@ class IMain(@BeanProperty val factory: ScriptEngineFactory, initialSettings: Set def this() = this(new Settings()) // the expanded prompt but without color escapes and without leading newline, for purposes of indenting - lazy val formatting: Formatting = new Formatting( - (replProps.promptString format Properties.versionNumberString).lines.toList.last.length - ) + lazy val formatting = Formatting.forPrompt(replProps.promptText) lazy val reporter: ReplReporter = new ReplReporter(this) import formatting.indentCode |