mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-07-22 21:00:22 -07:00
win_stat change return islink to islnk to match stat (#23196)
This commit is contained in:
parent
5918bebd6e
commit
4d1b97d1ae
5 changed files with 317 additions and 427 deletions
7
test/integration/targets/win_stat/files/set_share.ps1
Normal file
7
test/integration/targets/win_stat/files/set_share.ps1
Normal file
|
@ -0,0 +1,7 @@
|
|||
$share_name = $args[1]
|
||||
$share_stat = Get-WmiObject -Class Win32_Share -Filter "name='$share_name'"
|
||||
If ($share_stat) {
|
||||
$share_stat.Delete()
|
||||
}
|
||||
$wmi = [wmiClass] 'Win32_Share'
|
||||
$wmi.Create($args[0], $share_name, 0)
|
|
@ -1,6 +0,0 @@
|
|||
$share_stat = Get-WmiObject -Class Win32_Share -Filter "name='folder-share'"
|
||||
If ($share_stat) {
|
||||
$share_stat.Delete()
|
||||
}
|
||||
$wmi = [wmiClass] 'Win32_Share'
|
||||
$wmi.Create($args[0], 'folder-share', 0)
|
Loading…
Add table
Add a link
Reference in a new issue