Fix 'ls -g' shows colored results. If Ruby is post 1.9.2 global_variables returns Array of symbol. So change them to string to compare BUILTIN_GLOBALS or PSEUDO_GLOBALS.
This commit is contained in:
parent
107c7bcb72
commit
f3394b42ba
|
@ -33,6 +33,7 @@ class Pry
|
|||
|
||||
def format(globals)
|
||||
globals.sort_by(&:downcase).map do |name|
|
||||
name = name.to_s
|
||||
if PSEUDO_GLOBALS.include?(name)
|
||||
color(:pseudo_global, name)
|
||||
elsif BUILTIN_GLOBALS.include?(name)
|
||||
|
|
Loading…
Reference in New Issue