Module: GitCompound::Logger::ClassMethods

Defined in:
lib/git_compound/logger/colors.rb

Overview

Class methods core ext for String

Instance Method Summary collapse

Instance Method Details

#colorsObject



77
78
79
80
81
82
83
84
85
86
87
88
89
# File 'lib/git_compound/logger/colors.rb', line 77

def colors
  {
    black:   0,
    red:     1,
    green:   2,
    yellow:  3,
    blue:    4,
    magenta: 5,
    cyan:    6,
    white:   7,
    default: 9
  }
end

#disable_colorsObject



73
74
75
# File 'lib/git_compound/logger/colors.rb', line 73

def disable_colors
  @disable_colors ||= false
end

#disable_colors=(value) ⇒ Object



69
70
71
# File 'lib/git_compound/logger/colors.rb', line 69

def disable_colors=(value)
  @disable_colors = value && true
end

#modesObject



91
92
93
94
95
96
# File 'lib/git_compound/logger/colors.rb', line 91

def modes
  {
    default: 0,
    bold:    1
  }
end