mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
fixed: win_copy failure from a VirtualBox share to a local path (#33576)
This commit is contained in:
parent
dd041e6f72
commit
f13656782a
1 changed files with 0 additions and 15 deletions
|
@ -87,14 +87,6 @@ Function Copy-File($source, $dest) {
|
||||||
}
|
}
|
||||||
$diff += "+$dest`n"
|
$diff += "+$dest`n"
|
||||||
|
|
||||||
# make sure we set the attributes accordingly
|
|
||||||
if (-not $check_mode) {
|
|
||||||
$source_file = Get-Item -Path $source -Force
|
|
||||||
$dest_file = Get-Item -Path $dest -Force
|
|
||||||
$dest_file.Attributes = $source_file.Attributes
|
|
||||||
$dest_file.SetAccessControl($source_file.GetAccessControl())
|
|
||||||
}
|
|
||||||
|
|
||||||
$result.changed = $true
|
$result.changed = $true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -119,13 +111,6 @@ Function Copy-Folder($source, $dest) {
|
||||||
New-Item -Path $dest -ItemType Container -WhatIf:$check_mode | Out-Null
|
New-Item -Path $dest -ItemType Container -WhatIf:$check_mode | Out-Null
|
||||||
$diff += "+$dest\`n"
|
$diff += "+$dest\`n"
|
||||||
$result.changed = $true
|
$result.changed = $true
|
||||||
|
|
||||||
if (-not $check_mode) {
|
|
||||||
$source_folder = Get-Item -Path $source -Force
|
|
||||||
$dest_folder = Get-Item -Path $source -Force
|
|
||||||
$dest_folder.Attributes = $source_folder.Attributes
|
|
||||||
$dest_folder.SetAccessControl($source_folder.GetAccessControl())
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
$child_items = Get-ChildItem -Path $source -Force
|
$child_items = Get-ChildItem -Path $source -Force
|
||||||
|
|
Loading…
Reference in a new issue