Sha256: d6c34a59d2bc4b9757dce5e74c1ed7a287da45f74ff77f5548fd5c7c4c322a6c
Contents?: true
Size: 926 Bytes
Versions: 15
Compression:
Stored size: 926 Bytes
Contents
module MotherBrain module Cli module Shell module Ext class << self def included(base) base.send(:include, ClassMethods) base.extend(ClassMethods) end end module ClassMethods # Mute the output of this instance of UI until {#unmute!} is called def mute! @mute = true end # Unmute the output of this instance of UI until {#mute!} is called def unmute! @mute = false end def say(message = "", color = nil, force_new_line = nil) return if quiet? super(message, color) end alias_method :info, :say def warn(message) say(message, :yellow) end def deprecated(message) warn("[DEPRECATION] #{message}") end end end end end end
Version data entries
15 entries across 15 versions & 1 rubygems