Sha256: 38ec15a6ee1ca4b953cba1a028cbb49189c8e5480cc6bfef0ea3f79a5fac2f0a

Contents?: true

Size: 320 Bytes

Versions: 7

Compression:

Stored size: 320 Bytes

Contents

class String
  # colorization
  def colorize(color_code)
    "\e[#{color_code}m#{self}\e[0m"
  end

  def red
    colorize(31)
  end

  def green
    colorize(32)
  end

  def yellow
    colorize(33)
  end

  def blue
    colorize(34)
  end

  def pink
    colorize(35)
  end

  def light_blue
    colorize(36)
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
cocoapods-tdf-bin-0.0.23 lib/cocoapods-tdf-bin/helpers/string_helper.rb
cocoapods-tdf-bin-0.0.22 lib/cocoapods-tdf-bin/helpers/string_helper.rb
cocoapods-tdf-bin-0.0.21 lib/cocoapods-tdf-bin/helpers/string_helper.rb
cocoapods-tdf-bin-0.0.20 lib/cocoapods-tdf-bin/helpers/string_helper.rb
cocoapods-tdf-bin-0.0.19 lib/cocoapods-tdf-bin/helpers/string_helper.rb
cocoapods-tdf-bin-0.0.18 lib/cocoapods-tdf-bin/helpers/string_helper.rb
cocoapods-tdf-bin-0.0.17 lib/cocoapods-tdf-bin/helpers/string_helper.rb