Unblock a file with PowerShell?

前端 未结 13 1798
野性不改
野性不改 2020-12-08 02:52

I am trying to have PowerShell unblock a file in Win2K8 R2.

Does anyone have a pointer as to the syntax?

13条回答
  •  自闭症患者
    2020-12-08 02:59

    Oneliner to remove zone informarion(inspired by accepted answer) for all children (with correct quoting).

    get-childitem -rec | % { cmd /c "echo.>""$($_.FullName)"":Zone.Identifier" }
    

    Not strictly answer to the question, just want to make sure when I next come up with this problem there is solution already :).

    PS. Works in PS 2.0

提交回复
热议问题