use rbconfig for detecting Windows
This commit is contained in:
parent
d2b2e00939
commit
3edc923b22
|
@ -129,8 +129,10 @@ module VagrantPlugins
|
|||
|
||||
## Windows support for copying files, requesting elevated privileges if necessary
|
||||
module WindowsSupport
|
||||
require 'rbconfig'
|
||||
|
||||
def self.windows?
|
||||
ENV['OS'] === 'Windows_NT'
|
||||
RbConfig::CONFIG['host_os'] =~ /mswin|mingw|cygwin/
|
||||
end
|
||||
|
||||
require 'win32ole' if windows?
|
||||
|
|
Loading…
Reference in New Issue