winder update

This commit is contained in:
Matthew Hopkins 2014-03-18 09:00:11 -04:00
parent 18d3083f07
commit debf5e732a
1 changed files with 2 additions and 4 deletions

View File

@ -10,11 +10,9 @@ module VagrantPlugins
realhostfile = '/etc/inet/hosts'
move_cmd = 'mv'
elsif (machine.communicate.test("test -d $Env:SystemRoot"))
windir = nil
windir = ""
machine.communicate.execute("echo %SYSTEMROOT%", {:shell => :cmd}) do |type, contents|
if type == :stdout
windir = contents.gsub("\r\n", '')
end
windir << contents.gsub("\r\n", '') if type == :stdout
end
realhostfile = "#{windir}\\System32\\drivers\\etc\\hosts"
move_cmd = 'mv -force'