1
0
Fork 0
mirror of https://github.com/pry/pry.git synced 2022-11-09 12:35:05 -05:00

Pry::ColorPrinter.pp: add newline argument and pass it on to PP

This commit is contained in:
Débora Setton 2017-04-19 21:27:26 -03:00
parent 1f64463184
commit c7699e5b7a

View file

@ -12,8 +12,8 @@ class Pry
CodeRay::Encoders::Terminal::TOKEN_COLORS[:comment][:self] = "\e[1;34m"
def self.pp(obj, out = $>, width = 79)
q = ColorPrinter.new(out, width)
def self.pp(obj, out = $>, width = 79, newline = "\n")
q = ColorPrinter.new(out, width, newline)
q.guard_inspect_key { q.pp obj }
q.flush
out << "\n"