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

make correct_indentation color respect Pry.color

This commit is contained in:
John Mair 2012-04-19 11:53:53 +12:00
parent dd407b0e85
commit eae388a161

View file

@ -17,6 +17,8 @@ class Pry
# will be indented or un-indented by correctly. # will be indented or un-indented by correctly.
# #
class Indent class Indent
include Helpers::BaseHelpers
# String containing the spaces to be inserted before the next line. # String containing the spaces to be inserted before the next line.
attr_reader :indent_level attr_reader :indent_level
@ -224,7 +226,7 @@ class Pry
end end
whitespace = ' ' * overhang whitespace = ' ' * overhang
"#{move_up}#{prompt}#{CodeRay.scan(code, :ruby).term}#{whitespace}#{move_down}" "#{move_up}#{prompt}#{colorize_code(code)}#{whitespace}#{move_down}"
end end
end end
end end