Update TI-CMD.bat
This commit is contained in:
parent
0e2454e437
commit
26a112e021
1 changed files with 23 additions and 2 deletions
25
TI-CMD.bat
25
TI-CMD.bat
|
@ -1,10 +1,31 @@
|
|||
@echo off
|
||||
|
||||
:: Info and 1337 ha0xr colors
|
||||
title TrustedInstaller CMD
|
||||
color 0a
|
||||
echo "TrustedInstaller CMD is made by Sneed Group."
|
||||
echo TrustedInstaller CMD is made by Sneed Group.
|
||||
echo "Output stored at C:\ticmd-out.txt"
|
||||
|
||||
:A
|
||||
:: Allow user input
|
||||
set /p bp="TI:\> "
|
||||
|
||||
:: For sanity: Stop TrustedInstaller service before modifying it
|
||||
sc.exe stop TrustedInstaller
|
||||
sc.exe config TrustedInstaller binpath= "cmd /c %bp%"
|
||||
|
||||
:: Run user input as TrustedInstaller, output to plaintext file
|
||||
sc.exe config TrustedInstaller binpath= "cmd /c %bp% >> C:\ticmd-out.txt"
|
||||
|
||||
:: Start TrustedInstaller with new configuration
|
||||
sc.exe start TrustedInstaller
|
||||
|
||||
:: Stop to reconfigure to defaults
|
||||
sc.exe stop TrustedInstaller
|
||||
sc.exe config TrustedInstaller binpath= "%windir%\servicing\TrustedInstaller.exe"
|
||||
|
||||
:: Restart loop
|
||||
goto A
|
||||
|
||||
:: In case the user somehow exits the loop, reset the TrustedInstaller service back to default
|
||||
sc.exe stop TrustedInstaller
|
||||
sc.exe config TrustedInstaller binpath= "%windir%\servicing\TrustedInstaller.exe"
|
||||
|
|
Loading…
Reference in a new issue