相关疑难解决方法(0)

在PowerShell中自动确认删除

我正在运行以下命令:

get-childitem C:\temp\ -exclude *.svn-base,".svn" -recurse | foreach ($_) {remove-item $_.fullname}
Run Code Online (Sandbox Code Playgroud)

这经常提示我这样:

Confirm
The item at C:\temp\f\a\d has children and the Recurse parameter was not specified. If you continue,
all children will be removed with the item. Are you sure you want to continue?
[Y] Yes  [A] Yes to All  [N] No  [L] No to All  [S] Suspend  [?] Help (default is "Y"): 
Run Code Online (Sandbox Code Playgroud)

如何将其自动设置为"A"?

powershell scripting automation windows-vista

32
推荐指数
5
解决办法
8万
查看次数

标签 统计

automation ×1

powershell ×1

scripting ×1

windows-vista ×1