From 7bd32027f6a6573a98354e9acc4cdee2588027ad Mon Sep 17 00:00:00 2001 From: Mylloon Date: Fri, 27 Dec 2024 11:58:10 +0100 Subject: [PATCH] use winget when possible, keep vencord script as we need it for manually fix the installation after discord updates sometimes --- windows/installers/collapse.bat | 23 ----------------------- windows/installers/deceive.bat | 26 -------------------------- windows/installers/geek.bat | 24 ------------------------ windows11.bat | 30 +++++++++++------------------- 4 files changed, 11 insertions(+), 92 deletions(-) delete mode 100644 windows/installers/collapse.bat delete mode 100644 windows/installers/deceive.bat delete mode 100644 windows/installers/geek.bat diff --git a/windows/installers/collapse.bat b/windows/installers/collapse.bat deleted file mode 100644 index f4ea97a..0000000 --- a/windows/installers/collapse.bat +++ /dev/null @@ -1,23 +0,0 @@ -@ECHO OFF - -:: Start as administrator -fltmc >NUL 2>&1 || ( - PowerShell Start -Verb RunAs '%0' 2>NUL || ( - EXIT 1 - ) - EXIT 0 -) - -ECHO Collapse... -PowerShell -Command "" ^ - "$repo = 'CollapseLauncher/Collapse';" ^ - "$releases = \"https://api.github.com/repos/$repo/releases/latest\";" ^ - "$link = (Invoke-WebRequest $releases | ConvertFrom-Json)[0].assets.browser_download_url[0];" ^ - "$exe = 'collapse-installer.exe';" ^ - "$outFile = Join-Path -Path $env:TEMP -ChildPath $exe;" ^ - "Invoke-WebRequest -Uri $link -OutFile $outFile;" ^ - "Start-Process -Wait $outFile '/SUPPRESSMSGBOXES', '/VERYSILENT';" ^ - "Remove-Item -Force $outFile" - -IF NOT "%1"=="yes" PAUSE -EXIT /B diff --git a/windows/installers/deceive.bat b/windows/installers/deceive.bat deleted file mode 100644 index a6a1273..0000000 --- a/windows/installers/deceive.bat +++ /dev/null @@ -1,26 +0,0 @@ -@ECHO OFF - -:: Start as administrator -fltmc >NUL 2>&1 || ( - PowerShell Start -Verb RunAs '%0' 2>NUL || ( - EXIT 1 - ) - EXIT 0 -) - -ECHO Deceive... -MKDIR "%LOCALAPPDATA%\Deceive" 2>NUL -PowerShell -Command "" ^ - "$exe = 'Deceive.exe';" ^ - "$link = 'https://github.com/molenzwiebel/Deceive/releases/latest/download/' + $exe;" ^ - "$outfile = Join-Path -Path '%LOCALAPPDATA%\Deceive' -ChildPath $exe;" ^ - "Invoke-WebRequest -Uri $link -OutFile $outfile;" ^ - "$WshShell = New-Object -comObject WScript.Shell;" ^ - "$Shortcut = $WshShell.CreateShortcut('%APPDATA%\Microsoft\Windows\Start Menu\Programs\Deceive.lnk');" ^ - "$Shortcut.TargetPath = $outfile;" ^ - "$Shortcut.Save()" -REG ADD "HKCU\Software\Microsoft\Windows\CurrentVersion\Uninstall\Deceive" /f /v DisplayName /t REG_SZ /d "Deceive" -REG ADD "HKCU\Software\Microsoft\Windows\CurrentVersion\Uninstall\Deceive" /f /v InstallLocation /t REG_SZ /d "%LOCALAPPDATA%\Deceive" - -IF NOT "%1"=="yes" PAUSE -EXIT /B diff --git a/windows/installers/geek.bat b/windows/installers/geek.bat deleted file mode 100644 index 85c6074..0000000 --- a/windows/installers/geek.bat +++ /dev/null @@ -1,24 +0,0 @@ -@ECHO OFF - -:: Start as administrator -fltmc >NUL 2>&1 || ( - PowerShell Start -Verb RunAs '%0' 2>NUL || ( - EXIT 1 - ) - EXIT 0 -) - -ECHO Geek Uninstaller... -PowerShell -Command "" ^ - "$archive = '%TEMP%\geek.zip';" ^ - "Invoke-WebRequest -Uri https://geekuninstaller.com/geek.zip -OutFile $archive;" ^ - "Expand-Archive -Path $archive -DestinationPath '%ProgramFiles%\Geek Uninstaller' -Force;" ^ - "$WshShell = New-Object -comObject WScript.Shell;" ^ - "$Shortcut = $WshShell.CreateShortcut('%APPDATA%\Microsoft\Windows\Start Menu\Programs\Geek Uninstaller.lnk');" ^ - "$Shortcut.TargetPath = '%ProgramFiles%\Geek Uninstaller\geek.exe';" ^ - "$Shortcut.Save()" -REG ADD "HKCU\Software\Microsoft\Windows\CurrentVersion\Uninstall\geek" /f /v DisplayName /t REG_SZ /d "Geek Uninstaller" -REG ADD "HKCU\Software\Microsoft\Windows\CurrentVersion\Uninstall\geek" /f /v InstallLocation /t REG_SZ /d "%ProgramFiles%\Geek Uninstaller" - -IF NOT "%1"=="yes" PAUSE -EXIT /B diff --git a/windows11.bat b/windows11.bat index 6afe7a8..d7b12ca 100644 --- a/windows11.bat +++ b/windows11.bat @@ -98,7 +98,8 @@ SET ^"apps=^ TheDocumentFoundation.LibreOffice Armin2208.WindowsAutoNightMode ^ OBSProject.OBSStudio Xournal++.Xournal++ Microsoft.PowerToys KDE.KDEConnect ^ OpenWhisperSystems.Signal TenacityTeam.Tenacity Microsoft.PowerShell ^ - viarotel.Escrcpy Obsidian.Obsidian" + viarotel.Escrcpy Obsidian.Obsidian GeekUninstaller.GeekUninstaller ^ + Vendicated.Vencord" ECHO Apps... for %%i in (!apps!) do ( @@ -108,7 +109,8 @@ for %%i in (!apps!) do ( SET ^"games=^ RiotGames.LeagueOfLegends.EUW RiotGames.Valorant.EU Valve.Steam ppy.osu ^ HeroicGamesLauncher.HeroicGamesLauncher PrismLauncher.PrismLauncher ^ - pizzaboxer.Bloxstrap ebkr.r2modman" + pizzaboxer.Bloxstrap CollapseLauncher.Collapse molenzwiebel.Deceive ^ + ebkr.r2modman" ECHO Games... for %%i in (!games!) do ( @@ -133,9 +135,13 @@ PowerShell -Command "Install-PackageProvider -Name NuGet -Force" PowerShell -Command "Install-Module -Name PSWindowsUpdate -Force" -:: === Geek Uninstaller == -PowerShell -Command "Invoke-WebRequest -Uri !repo!/windows/installers/geek.bat -OutFile '%TEMP%\geek.bat'" -CMD /c "%TEMP%\geek.bat" yes +:: === Geek Uninstaller icon == +ECHO Geek Uninstaller icon... +PowerShell -Command "" ^ + "$WshShell = New-Object -comObject WScript.Shell;" ^ + "$Shortcut = $WshShell.CreateShortcut('%APPDATA%\Microsoft\Windows\Start Menu\Programs\Geek Uninstaller.lnk');" ^ + "$Shortcut.TargetPath = '%LOCALAPPDATA%\Microsoft\WinGet\Packages\GeekUninstaller.GeekUninstaller_Microsoft.Winget.Source_8wekyb3d8bbwe';" ^ + "$Shortcut.Save()" :: === LosslessCut == @@ -148,11 +154,6 @@ PowerShell -Command "Invoke-WebRequest -Uri !repo!/windows/installers/dsr.bat -O CMD /c "%TEMP%\dsr.bat" yes -:: === Vencord == -:: Use already downloaded script -CMD /c "!local!\vencord_installer.bat" yes - - :: === OpenTabletDriver == ECHO OpenTabletDriver... PowerShell -Command "" ^ @@ -201,11 +202,6 @@ PowerShell -Command "Invoke-WebRequest -Uri !repo!/windows/installers/nowt.bat - CMD /c "%TEMP%\nowt.bat" yes -:: === Deceive == -PowerShell -Command "Invoke-WebRequest -Uri !repo!/windows/installers/deceive.bat -OutFile '%TEMP%\deceive.bat'" -CMD /c "%TEMP%\deceive.bat" yes - - :: === Minecraft == :: Copy shortcut of Prism Launcher to a Minecraft shortcut COPY /Y "!startmenu!\Prism Launcher.lnk" "!startmenu!\Minecraft.lnk" @@ -276,10 +272,6 @@ ECHO About OBS, you may need to adjust the screen ID by opening the OBS app ECHO in the systray as it may be not the same as the one presaved. -:: === miHoYo Games launcher == -PowerShell -Command "Invoke-WebRequest -Uri !repo!/windows/installers/collapse.bat -OutFile '%TEMP%\collapse.bat'" -CMD /c "%TEMP%\collapse.bat" yes - :: Fix games shortcut PowerShell -Command "Invoke-WebRequest -Uri !repo!/windows/apply_mihoyo_shortcut.bat -OutFile '%TEMP%\apply_mihoyo_shortcut.bat'" CMD /c "%TEMP%\apply_mihoyo_shortcut.bat" yes