pry--pry/lib/pry/commands/show_input.rb

14 lines
342 B
Ruby

class Pry
class Command::ShowInput < Pry::ClassCommand
match 'show-input'
group 'Editing'
description 'Show the contents of the input buffer for the current multi-line expression.'
def process
output.puts Code.new(eval_string).with_line_numbers
end
end
Pry::Commands.add_command(Pry::Command::ShowInput)
end