From 02657c40d3fcfb9742c3cf61294e592ed513e9b3 Mon Sep 17 00:00:00 2001 From: Mylloon Date: Sat, 11 Nov 2023 17:22:52 +0100 Subject: [PATCH] clean DSR if already exists --- windows11.bat | 1 + 1 file changed, 1 insertion(+) diff --git a/windows11.bat b/windows11.bat index 06c54af..428f485 100644 --- a/windows11.bat +++ b/windows11.bat @@ -203,6 +203,7 @@ PowerShell -Command "" ^ "$link = (Invoke-WebRequest $releases | ConvertFrom-Json)[0].assets.browser_download_url;" ^ "$archive = '%TEMP%\dsr.zip';" ^ "Invoke-WebRequest -Uri $link -OutFile $archive;" ^ + "Remove-Item '%LOCALAPPDATA%\DSR' -Recurse -ErrorAction SilentlyContinue;" ^ "Expand-Archive -Path $archive -DestinationPath '%LOCALAPPDATA%\DSR' -Force;" ^ "Move-Item -Path '%LOCALAPPDATA%\DSR\dsr-win32-x64\*' -Destination '%LOCALAPPDATA%\DSR' -Force;" ^ "Remove-Item '%LOCALAPPDATA%\DSR\dsr-win32-x64';" ^