Module: OpenStudio::Workflow::Util::IO
- Included in:
- EnergyPlus
- Defined in:
- lib/openstudio/workflow/util/io.rb
Instance Method Summary collapse
Instance Method Details
#is_windows? ⇒ Boolean
5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 |
# File 'lib/openstudio/workflow/util/io.rb', line 5 def is_windows? win_patterns = [ /bccwin/i, /cygwin/i, /djgpp/i, /mingw/i, /mswin/i, /wince/i ] case RUBY_PLATFORM when *win_patterns return true else return false end end |
#popen_command(command) ⇒ Object
23 24 25 26 27 28 29 |
# File 'lib/openstudio/workflow/util/io.rb', line 23 def popen_command(command) result = command if is_windows? result = command.tr('/', '\\') end return result end |