We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 302337b commit bb53e42Copy full SHA for bb53e42
lib/vagrant-hostmanager/hosts_file/updater.rb
@@ -36,14 +36,13 @@ def update_guest(machine)
36
37
# upload modified file and remove temporary file
38
machine.communicate.upload(file, '/tmp/hosts')
39
- machine.communicate.sudo("#{move_cmd} /tmp/hosts #{realhostfile}")
+ if windir
40
+ machine.communicate.sudo("#{move_cmd} /tmp/hosts/hosts.#{machine.name} #{realhostfile}")
41
+ else
42
+ machine.communicate.sudo("#{move_cmd} /tmp/hosts #{realhostfile}")
43
+ end
44
end
45
- # i have no idea if this is a windows competibility issue or not, but sometimes it dosen't work on my machine
- begin
- FileUtils.rm(file)
- rescue Exception => e
46
- end
47
48
49
def update_host
0 commit comments