Merge pull request #8588 from aligenttimaslat/bugfix/rsync_mkdir_on_windows

Fix a problem when using rsync folders on windows clients
This commit is contained in:
Chris Roberts 2017-06-14 16:41:36 -07:00 committed by GitHub
commit 60a438396f
2 changed files with 2 additions and 2 deletions

View File

@ -13,7 +13,7 @@ module VagrantPlugins
machine.communicate.tap do |comm|
# rsync does not construct any gaps in the path to the target directory
# make sure that all subdirectories are created
comm.execute("mkdir '#{opts[:guestpath]}'")
comm.execute("mkdir -p '#{opts[:guestpath]}'")
end
end
end

View File

@ -19,7 +19,7 @@ describe "VagrantPlugins::GuestWindows::Cap::RSync" do
describe ".rsync_pre" do
it 'makes the guestpath directory with mkdir' do
communicator.expect_command("mkdir '/sync_dir'")
communicator.expect_command("mkdir -p '/sync_dir'")
described_class.rsync_pre(machine, guestpath: '/sync_dir')
end
end