diff --git a/windows/update.bat b/windows/update.bat index 6f53cbc..74f7284 100644 --- a/windows/update.bat +++ b/windows/update.bat @@ -1,4 +1,5 @@ @ECHO OFF +SETLOCAL ENABLEDELAYEDEXPANSION :: Start as administrator fltmc >NUL 2>&1 || ( @@ -8,11 +9,22 @@ fltmc >NUL 2>&1 || ( EXIT 0 ) -:: Windows programs +:: Exclusion list +SET ^"exclusions=^ + Spotify.Spotify" + +:: Apply exclude list +for %%i in (!exclusions!) do ( + winget pin add --id %%i >NUL +) + +:: Update Windows programs winget upgrade -h --all -:: NOTE: If you want to not update a package, you can pin it: -:: winget pin add --id ID.OF.THE.APP +:: Clean list of exclusions +for %%i in (!exclusions!) do ( + winget pin remove --id %%i >NUL +) :: Windows Update PowerShell -Command "Set-ExecutionPolicy Bypass -Scope Process;" ^