do not update winget bundle, and spotufy exclusion requires admin privileges

This commit is contained in:
Mylloon 2025-04-22 20:56:47 +02:00
parent 67913884d5
commit de665b5171
Signed by: Anri
GPG key ID: A82D63DFF8D1317F
2 changed files with 20 additions and 14 deletions

View file

@ -12,11 +12,11 @@ MKDIR "!local!" 2>NUL
fltmc >NUL 2>&1 || (
ECHO Please wait until the administrator popup appears.
:: === Update winget to latest version ==
PowerShell -Command "" ^
"Invoke-WebRequest -Uri https://aka.ms/getwinget -OutFile winget.msixbundle;" ^
"Add-AppPackage -ForceApplicationShutdown .\winget.msixbundle;" ^
"del .\winget.msixbundle"
@REM :: === Update winget to latest version ==
@REM PowerShell -Command "" ^
@REM "Invoke-WebRequest -Uri https://aka.ms/getwinget -OutFile winget.msixbundle;" ^
@REM "Add-AppPackage -ForceApplicationShutdown .\winget.msixbundle;" ^
@REM "del .\winget.msixbundle"
:: === Scripts from ./windows directory ==
@ -34,8 +34,6 @@ fltmc >NUL 2>&1 || (
:: Use already downloaded script
ECHO Y| CMD /c "!local!\blockthespot.bat" yes
PowerShell -Command "Stop-Process -Name Spotify -ErrorAction SilentlyContinue"
:: Defender exclusion
PowerShell -Command "Add-MpPreference -ExclusionPath '%APPDATA%\Spotify'"
:: Start as administrator
PowerShell Start -Verb RunAs "%0 noskipadmin" 2>NUL || (
@ -54,6 +52,11 @@ IF NOT "%1"=="noskipadmin" (
EXIT 0
)
:: === Spotify
:: Defender exclusion
PowerShell -Command "Add-MpPreference -ExclusionPath '%APPDATA%\Spotify'"
:: === Registery modifications ==
CMD /c "!local!\reg_fixes.bat" yes

View file

@ -12,11 +12,11 @@ MKDIR "!local!" 2>NUL
fltmc >NUL 2>&1 || (
ECHO Please wait until the administrator popup appears.
:: === Update winget to latest version ==
PowerShell -Command "" ^
"Invoke-WebRequest -Uri https://aka.ms/getwinget -OutFile winget.msixbundle;" ^
"Add-AppPackage -ForceApplicationShutdown .\winget.msixbundle;" ^
"del .\winget.msixbundle"
@REM :: === Update winget to latest version ==
@REM PowerShell -Command "" ^
@REM "Invoke-WebRequest -Uri https://aka.ms/getwinget -OutFile winget.msixbundle;" ^
@REM "Add-AppPackage -ForceApplicationShutdown .\winget.msixbundle;" ^
@REM "del .\winget.msixbundle"
:: === Scripts from ./windows directory ==
@ -34,8 +34,6 @@ fltmc >NUL 2>&1 || (
:: Use already downloaded script
ECHO Y| CMD /c "!local!\blockthespot.bat" yes
PowerShell -Command "Stop-Process -Name Spotify -ErrorAction SilentlyContinue"
:: Defender exclusion
PowerShell -Command "Add-MpPreference -ExclusionPath '%APPDATA%\Spotify'"
:: Start as administrator
PowerShell Start -Verb RunAs "%0 noskipadmin" 2>NUL || (
@ -54,6 +52,11 @@ IF NOT "%1"=="noskipadmin" (
EXIT 0
)
:: === Spotify
:: Defender exclusion
PowerShell -Command "Add-MpPreference -ExclusionPath '%APPDATA%\Spotify'"
:: === Registery modifications ==
CMD /c "!local!\reg_fixes.bat" yes