mirror of
https://github.com/ruby/ruby.git
synced 2026-01-27 04:24:23 +00:00
Add a warning message and --legacy of an alias of --singleline
This commit is contained in:
parent
9d6f78822c
commit
eee70b41d4
@ -82,6 +82,12 @@ module IRB
|
||||
case use_multiline?
|
||||
when nil
|
||||
if STDIN.tty? && IRB.conf[:PROMPT_MODE] != :INF_RUBY && !use_singleline?
|
||||
# Both of multiline mode and singleline mode aren't specified.
|
||||
puts <<~EOM
|
||||
This version of IRB is drastically different from the previous version.
|
||||
If you hit any issues, you can use "irb --legacy" to run the old version.
|
||||
If you want to just erase this message, please use "irb --multiline".
|
||||
EOM
|
||||
@io = ReidlineInputMethod.new
|
||||
else
|
||||
@io = nil
|
||||
|
||||
@ -161,7 +161,7 @@ module IRB # :nodoc:
|
||||
end
|
||||
when "--noinspect"
|
||||
@CONF[:INSPECT_MODE] = false
|
||||
when "--singleline", "--readline"
|
||||
when "--singleline", "--readline", "--legacy"
|
||||
@CONF[:USE_SINGLELINE] = true
|
||||
when "--nosingleline", "--noreadline"
|
||||
@CONF[:USE_SINGLELINE] = false
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user