Sha256: 8ef2db31f0fe35b619153756f3afb4a6af8b2af284d6ef5f201eaf9b260c25f9
Contents?: true
Size: 324 Bytes
Versions: 9
Compression:
Stored size: 324 Bytes
Contents
# Taken from ActiveSupport: http://api.rubyonrails.org/classes/Kernel.html#method-i-silence_stream def silence_stream(stream) old_stream = stream.dup stream.reopen(RbConfig::CONFIG["host_os"] =~ /mswin|mingw/ ? "NUL:" : "/dev/null") stream.sync = true yield ensure stream.reopen(old_stream) old_stream.close end
Version data entries
9 entries across 9 versions & 1 rubygems