Created
August 7, 2020 10:20
-
-
Save Cologler/ef4c6f853a443013c8308aac98206a11 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# base-on https://zhuanlan.zhihu.com/p/104046487 | |
# clean patchs | |
Get-ChildItem -Path TCLS/patchs | Remove-Item | |
# clean Cross | |
Get-ChildItem -Path Cross | Where-Object -Property Name -NE -Value 'Apps' | Remove-Item –Recurse -Force | |
Get-ChildItem -Path Cross/Apps | Where-Object -Property Name -NE -Value 'Apps' | Remove-Item –Recurse -Force | |
# mark readonly. | |
$cross = Get-Item -Path Cross | |
if (!($cross.Attributes -band [system.IO.FileAttributes]::ReadOnly)) { | |
$cross.Attributes += 'ReadOnly' | |
} | |
# clean TPHelper | |
Get-ChildItem -Path TCLS/TenProtect/TP | Remove-Item –Recurse -Force |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment