From 538b1f8bcd9d4b696b6f7e5e882b15667e24f66f Mon Sep 17 00:00:00 2001 From: Mylloon Date: Fri, 11 Aug 2023 14:27:37 +0200 Subject: [PATCH 1/3] create a vencord installer --- windows/vencord_installer.bat | 20 ++++++++++++++++++++ windows11.bat | 21 ++++++++------------- 2 files changed, 28 insertions(+), 13 deletions(-) create mode 100644 windows/vencord_installer.bat diff --git a/windows/vencord_installer.bat b/windows/vencord_installer.bat new file mode 100644 index 0000000..4a089f3 --- /dev/null +++ b/windows/vencord_installer.bat @@ -0,0 +1,20 @@ +@ECHO OFF + +ECHO Ferme Discord +TASKKILL /im Discord.exe /F + +ECHO Installe Vencord +PowerShell -Command "$link = 'https://github.com/Vencord/Installer/releases/latest/download/VencordInstallerCli.exe';" ^ + "$file = 'vencord.exe';" ^ + "$outfile = Join-Path -Path $env:TEMP -ChildPath $file;" ^ + "Invoke-WebRequest -Uri $link -OutFile $outfile;" ^ + "cd $env:TEMP;" ^ + "ECHO 1| & $outfile -install" + +IF NOT "%1"=="noskip" ( + :: Restart Discord + "%LOCALAPPDATA%\Discord\Update.exe" + + PAUSE +) +EXIT /B diff --git a/windows11.bat b/windows11.bat index 5708a38..a0748ac 100644 --- a/windows11.bat +++ b/windows11.bat @@ -113,20 +113,11 @@ for %%i in (!games!) do ( !pmi! %%i ) -:: Install Vencord -TASKKILL /im Discord.exe /F -PowerShell -Command "$link = 'https://github.com/Vencord/Installer/releases/latest/download/VencordInstallerCli.exe';" ^ - "$file = 'vencord.exe';" ^ - "$outfile = Join-Path -Path $env:TEMP -ChildPath $file;" ^ - "Invoke-WebRequest -Uri $link -OutFile $outfile;" ^ - "cd $env:TEMP;" ^ - "ECHO 1| & $outfile -install" - -:: Install WSL +:: === Install WSL == wsl --install --no-launch wsl --unregister Ubuntu -:: Install Geek Uninstaller +:: === Install 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';" ^ @@ -137,7 +128,7 @@ PowerShell -Command "$archive = '%TEMP%\geek.zip';" ^ 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" -:: Install LosslessCut +:: === Install LosslessCut == PowerShell -Command "$archive = 'LosslessCut-win-x64.7z';" ^ "$link = 'https://github.com/mifi/lossless-cut/releases/latest/download/' + $archive;" ^ "$outfile = Join-Path -Path $env:TEMP -ChildPath $archive;" ^ @@ -151,7 +142,7 @@ PowerShell -Command "$archive = 'LosslessCut-win-x64.7z';" ^ REG ADD "HKCU\Software\Microsoft\Windows\CurrentVersion\Uninstall\LosslessCut" /f /v DisplayName /t REG_SZ /d "LosslessCut" REG ADD "HKCU\Software\Microsoft\Windows\CurrentVersion\Uninstall\LosslessCut" /f /v InstallLocation /t REG_SZ /d "%ProgramFiles%\LosslessCut" -:: Install DSR +:: === Install DSR == PowerShell -Command "$archive = '%TEMP%\dsr.zip';" ^ "Invoke-WebRequest -Uri https://git.mylloon.fr/attachments/9fa1cf45-ce58-443a-a061-596051405336 -OutFile $archive;" ^ "Expand-Archive -Path $archive -DestinationPath '%ProgramFiles%\DSR';" ^ @@ -204,6 +195,10 @@ PowerShell -Command "Invoke-WebRequest -Uri !repo!/windows/ctmpf.bat -OutFile '% PowerShell -Command "Invoke-WebRequest -Uri !repo!/windows/update.bat -OutFile '%HOMEPATH%\Documents\Local\update.bat'" PowerShell -Command "Invoke-WebRequest -Uri !repo!/windows/fix_nvidia_wsl.bat -OutFile '%HOMEPATH%\Documents\Local\fix_nvidia_wsl.bat'" PowerShell -Command "Invoke-WebRequest -Uri !repo!/windows/fix_obs_shortcut.bat -OutFile '%HOMEPATH%\Documents\Local\fix_obs_shortcut.bat'" +PowerShell -Command "Invoke-WebRequest -Uri !repo!/windows/vencord_installer.bat -OutFile '%HOMEPATH%\Documents\Local\vencord_installer.bat'" + +:: === Install Vencord == +CMD /c "%HOMEPATH%\Documents\Local\vencord_installer.bat" noskip :: === Install OpenTabletDriver == :: Download From 0074de7911440c537bb5d3e9efea4826ecad80a5 Mon Sep 17 00:00:00 2001 From: Mylloon Date: Fri, 11 Aug 2023 14:28:22 +0200 Subject: [PATCH 2/3] use "yes" option instead of "noskip" --- windows/blockthespot.bat | 2 +- windows/fix_obs_shortcut.bat | 2 +- windows/vencord_installer.bat | 2 +- windows11.bat | 6 +++--- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/windows/blockthespot.bat b/windows/blockthespot.bat index fd58cc6..bbb0b92 100644 --- a/windows/blockthespot.bat +++ b/windows/blockthespot.bat @@ -28,5 +28,5 @@ DEL %HOMEPATH%\Desktop\Spotify.lnk 2>NUL ie4uinit -show ECHO Suppression du raccourci du bureau -IF NOT "%1"=="noskip" PAUSE +IF NOT "%1"=="yes" PAUSE EXIT /B diff --git a/windows/fix_obs_shortcut.bat b/windows/fix_obs_shortcut.bat index c55c608..e552542 100644 --- a/windows/fix_obs_shortcut.bat +++ b/windows/fix_obs_shortcut.bat @@ -15,5 +15,5 @@ PowerShell -Command "$WshShell = New-Object -COM WScript.Shell;" ^ "$Shortcut.Arguments = '--profile ""ANRI GAMING (PROFIL)"""" --multi';" ^ "$Shortcut.Save()" -IF NOT "%1"=="noskip" PAUSE +IF NOT "%1"=="yes" PAUSE EXIT /B diff --git a/windows/vencord_installer.bat b/windows/vencord_installer.bat index 4a089f3..152d104 100644 --- a/windows/vencord_installer.bat +++ b/windows/vencord_installer.bat @@ -11,7 +11,7 @@ PowerShell -Command "$link = 'https://github.com/Vencord/Installer/releases/late "cd $env:TEMP;" ^ "ECHO 1| & $outfile -install" -IF NOT "%1"=="noskip" ( +IF NOT "%1"=="yes" ( :: Restart Discord "%LOCALAPPDATA%\Discord\Update.exe" diff --git a/windows11.bat b/windows11.bat index a0748ac..8e586c7 100644 --- a/windows11.bat +++ b/windows11.bat @@ -10,7 +10,7 @@ fltmc >NUL 2>&1 || ( :: === Install Spotify == PowerShell -Command "Invoke-WebRequest -Uri !repo!/windows/blockthespot.bat -OutFile '%HOMEPATH%\Documents\Local\blockthespot.bat'" DEL "%APPDATA%\Spotify" - ECHO Y| CMD /c "%HOMEPATH%\Documents\Local\blockthespot.bat" noskip + ECHO Y| CMD /c "%HOMEPATH%\Documents\Local\blockthespot.bat" yes PowerShell -Command "Stop-Process -Name Spotify -ErrorAction SilentlyContinue" :: Start as administrator @@ -198,7 +198,7 @@ PowerShell -Command "Invoke-WebRequest -Uri !repo!/windows/fix_obs_shortcut.bat PowerShell -Command "Invoke-WebRequest -Uri !repo!/windows/vencord_installer.bat -OutFile '%HOMEPATH%\Documents\Local\vencord_installer.bat'" :: === Install Vencord == -CMD /c "%HOMEPATH%\Documents\Local\vencord_installer.bat" noskip +CMD /c "%HOMEPATH%\Documents\Local\vencord_installer.bat" yes :: === Install OpenTabletDriver == :: Download @@ -238,7 +238,7 @@ PowerShell -Command "$WshShell = New-Object -COM WScript.Shell;" ^ "--startreplaybuffer --profile ""ReplayBuffer"""" --scene ""ReplayBuffer""""';" ^ "$Shortcut.Save()" :: Default shortcut should start default profile -CALL %HOMEPATH%\Documents\Local\fix_obs_shortcut.bat noskip +CALL %HOMEPATH%\Documents\Local\fix_obs_shortcut.bat yes :: Allow system to go in sleep mode when OBS is running powercfg -requestsoverride process obs64.exe display system awaymode From 28337a4c5166c4c5d9e0088e4ce53c0089fb1cd7 Mon Sep 17 00:00:00 2001 From: Mylloon Date: Fri, 11 Aug 2023 14:29:29 +0200 Subject: [PATCH 3/3] Comment the whole OBS section as I am using Shadowplay now --- windows11.bat | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/windows11.bat b/windows11.bat index 8e586c7..7d1d6f8 100644 --- a/windows11.bat +++ b/windows11.bat @@ -229,18 +229,18 @@ PowerShell -Command "Expand-Archive -Path '%TEMP%\WindowsInk.zip' -DestinationPa :: Rename shortcut for Minecraft RENAME "%APPDATA%\Microsoft\Windows\Start Menu\Programs\Prism Launcher.lnk" Minecraft.lnk -:: Startup OBS replay buffer -PowerShell -Command "$WshShell = New-Object -COM WScript.Shell;" ^ - "$Shortcut = $WshShell.CreateShortcut('%APPDATA%\Microsoft\Windows\Start Menu\Programs\Startup\OBS.lnk');" ^ - "$Shortcut.TargetPath = '%ProgramFiles%\obs-studio\bin\64bit\obs64.exe';" ^ - "$Shortcut.WorkingDirectory = '%ProgramFiles%\obs-studio\bin\64bit';" ^ - "$Shortcut.Arguments = '--disable-missing-files-check --minimize-to-tray " ^ - "--startreplaybuffer --profile ""ReplayBuffer"""" --scene ""ReplayBuffer""""';" ^ - "$Shortcut.Save()" -:: Default shortcut should start default profile -CALL %HOMEPATH%\Documents\Local\fix_obs_shortcut.bat yes -:: Allow system to go in sleep mode when OBS is running -powercfg -requestsoverride process obs64.exe display system awaymode +:: :: Startup OBS replay buffer +:: PowerShell -Command "$WshShell = New-Object -COM WScript.Shell;" ^ +:: "$Shortcut = $WshShell.CreateShortcut('%APPDATA%\Microsoft\Windows\Start Menu\Programs\Startup\OBS.lnk');" ^ +:: "$Shortcut.TargetPath = '%ProgramFiles%\obs-studio\bin\64bit\obs64.exe';" ^ +:: "$Shortcut.WorkingDirectory = '%ProgramFiles%\obs-studio\bin\64bit';" ^ +:: "$Shortcut.Arguments = '--disable-missing-files-check --minimize-to-tray " ^ +:: "--startreplaybuffer --profile ""ReplayBuffer"""" --scene ""ReplayBuffer""""';" ^ +:: "$Shortcut.Save()" +:: :: Default shortcut should start default profile +:: CALL %HOMEPATH%\Documents\Local\fix_obs_shortcut.bat yes +:: :: Allow system to go in sleep mode when OBS is running +:: powercfg -requestsoverride process obs64.exe display system awaymode ECHO Fais un tour des parametres Windows, apres avoir fait toutes les mises a jour disponible sur le PC. ECHO Enfin, redemarre l'ordinateur