Class: String
Instance Method Summary collapse
Instance Method Details
#colorize(color_code) ⇒ Object
35 36 37 |
# File 'lib/slimkeyfy/console/printer.rb', line 35 def colorize(color_code) "\e[#{color_code}m#{self}\e[0m" end |
#green ⇒ Object
41 42 43 |
# File 'lib/slimkeyfy/console/printer.rb', line 41 def green colorize(32) end |
#red ⇒ Object
38 39 40 |
# File 'lib/slimkeyfy/console/printer.rb', line 38 def red colorize(31) end |
#white ⇒ Object
47 48 49 |
# File 'lib/slimkeyfy/console/printer.rb', line 47 def white colorize(37) end |
#yellow ⇒ Object
44 45 46 |
# File 'lib/slimkeyfy/console/printer.rb', line 44 def yellow colorize(34) end |