Sha256: 2ab642774035ec02e3a6385cec41515c67f1de74125e1046ba50ac9d3f05ac7f
Contents?: true
Size: 264 Bytes
Versions: 12
Compression:
Stored size: 264 Bytes
Contents
module Reporting 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 end
Version data entries
12 entries across 12 versions & 4 rubygems