function set-rights ($path) {
    $p = Get-Item $path;
    if ($p.Attributes -eq 'Directory') {
        foreach ($child in Get-ChildItem $p.FullName) {
            set-X($child.FullName);
        }
    }
    icacls $p.FullName /grant 'everyone:f';
}

$path="E:\abc";
set-rights($t);

 

相关文章:

  • 2021-09-20
  • 2021-12-10
  • 2021-11-18
  • 2021-11-24
  • 2021-11-17
  • 2021-09-26
猜你喜欢
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-06-09
  • 2021-12-12
  • 2021-11-20
  • 2021-08-06
相关资源
相似解决方案