Method: ChildProcess.os
- Defined in:
- lib/childprocess.rb
.os ⇒ Object
87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 |
# File 'lib/childprocess.rb', line 87 def os @os ||= ( require "rbconfig" host_os = RbConfig::CONFIG['host_os'].downcase case host_os when /linux/ :linux when /darwin|mac os/ :macosx when /mswin|msys|mingw32/ :windows when /cygwin/ :cygwin when /solaris|sunos/ :solaris when /bsd/ :bsd when /aix/ :aix else raise Error, "unknown os: #{host_os.inspect}" end ) end |