Module: ExceptionDetails::LogColorHelpers

Included in:
Exception
Defined in:
lib/exception_details/log_color_helpers.rb

Instance Method Summary collapse

Instance Method Details

#bg_black(str) ⇒ Object



12
# File 'lib/exception_details/log_color_helpers.rb', line 12

def bg_black(str);       "\033[40m#{str}\0330m"  end

#bg_blue(str) ⇒ Object



16
# File 'lib/exception_details/log_color_helpers.rb', line 16

def bg_blue(str);        "\033[44m#{str}\033[0m" end

#bg_brown(str) ⇒ Object



15
# File 'lib/exception_details/log_color_helpers.rb', line 15

def bg_brown(str);       "\033[43m#{str}\033[0m" end

#bg_cyan(str) ⇒ Object



18
# File 'lib/exception_details/log_color_helpers.rb', line 18

def bg_cyan(str);        "\033[46m#{str}\033[0m" end

#bg_gray(str) ⇒ Object



19
# File 'lib/exception_details/log_color_helpers.rb', line 19

def bg_gray(str);        "\033[47m#{str}\033[0m" end

#bg_green(str) ⇒ Object



14
# File 'lib/exception_details/log_color_helpers.rb', line 14

def bg_green(str);       "\033[42m#{str}\033[0m" end

#bg_magenta(str) ⇒ Object



17
# File 'lib/exception_details/log_color_helpers.rb', line 17

def bg_magenta(str);     "\033[45m#{str}\033[0m" end

#bg_red(str) ⇒ Object



13
# File 'lib/exception_details/log_color_helpers.rb', line 13

def bg_red(str);         "\033[41m#{str}\033[0m" end

#black(str) ⇒ Object



4
# File 'lib/exception_details/log_color_helpers.rb', line 4

def black(str);          "\033[30m#{str}\033[0m" end

#blue(str) ⇒ Object



8
# File 'lib/exception_details/log_color_helpers.rb', line 8

def blue(str);           "\033[34m#{str}\033[0m" end

#bold(str) ⇒ Object



20
# File 'lib/exception_details/log_color_helpers.rb', line 20

def bold(str);           "\033[1m#{str}\033[22m" end

#brown(str) ⇒ Object



7
# File 'lib/exception_details/log_color_helpers.rb', line 7

def brown(str);          "\033[33m#{str}\033[0m" end

#cyan(str) ⇒ Object



10
# File 'lib/exception_details/log_color_helpers.rb', line 10

def cyan(str);           "\033[36m#{str}\033[0m" end

#gray(str) ⇒ Object



11
# File 'lib/exception_details/log_color_helpers.rb', line 11

def gray(str);           "\033[37m#{str}\033[0m" end

#green(str) ⇒ Object



6
# File 'lib/exception_details/log_color_helpers.rb', line 6

def green(str);          "\033[32m#{str}\033[0m" end

#magenta(str) ⇒ Object



9
# File 'lib/exception_details/log_color_helpers.rb', line 9

def magenta(str);        "\033[35m#{str}\033[0m" end

#red(str) ⇒ Object



5
# File 'lib/exception_details/log_color_helpers.rb', line 5

def red(str);            "\033[31m#{str}\033[0m" end

#reverse_color(str) ⇒ Object



21
# File 'lib/exception_details/log_color_helpers.rb', line 21

def reverse_color(str);  "\033[7m#{str}\033[27m" end