Mercurial > codedump
comparison vegasman/manual.bat @ 80:8050240a2306
Add manual vegas installer
committer: GitHub <noreply@github.com>
| author | Paper <37962225+mrpapersonic@users.noreply.github.com> |
|---|---|
| date | Wed, 06 Jul 2022 09:51:32 -0400 |
| parents | |
| children |
comparison
equal
deleted
inserted
replaced
| 79:bc2e83fbfbce | 80:8050240a2306 |
|---|---|
| 1 @echo off | |
| 2 SETLOCAL EnableDelayedExpansion | |
| 3 REM Manual Vegas Pro installer | |
| 4 REM Made by Paper because the Vegas installer | |
| 5 REM wasn't fucking working... | |
| 6 REM | |
| 7 REM Run as admin!!! | |
| 8 | |
| 9 if not exist "%~dp0\bin\7zr.exe" ( | |
| 10 call :downloadfile "https://www.7-zip.org/a/7zr.exe" "%~dp0\bin\7zr.exe" | |
| 11 ) | |
| 12 | |
| 13 REM cls | |
| 14 echo Extracting Vegas files... please wait... | |
| 15 echo. | |
| 16 | |
| 17 set "shared=C:\Program Files (x86)\Sony" | |
| 18 "%~dp0\bin\7zr.exe" x -y "%~dp0\7z\Vegas Pro 13.0.7z" -o"C:\Program Files\Sony" | |
| 19 "%~dp0\bin\7zr.exe" x -y "%~dp0\7z\Shared Plug-ins.7z" -o"C:\Program Files (x86)\Sony" | |
| 20 "%~dp0\bin\7zr.exe" x -y "%~dp0\7z\Start Menu.7z" -o"C:\ProgramData\Microsoft\Windows\Start Menu" | |
| 21 "%~dp0\bin\7zr.exe" x -y "%~dp0\7z\Installer.7z" -o"C:\Windows\Installer" | |
| 22 "%~dp0\bin\7zr.exe" x -y "%~dp0\7z\ProgramData.7z" -o"C:\ProgramData\Sony" | |
| 23 | |
| 24 REM need this to get audio plugins working... | |
| 25 for %%i in ("%shared%\Shared Plug-Ins\Audio_x64\*.dll") do ( | |
| 26 regsvr32 /s "%%i" | |
| 27 if %errorlevel% equ 0 echo %%~nxi registered! | |
| 28 ) | |
| 29 | |
| 30 reg.exe import "%~dp0\vegas.reg" | |
| 31 | |
| 32 echo Windows Registry Editor Version 5.00 > vegasuser.reg | |
| 33 echo.>> vegasuser.reg | |
| 34 echo [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\App Paths\vegas130.exe]>> vegasuser.reg | |
| 35 echo "C:\\Users\\%USERNAME%\\AppData\\Local\\Sony\\ErrorReport\\"="1">> vegasuser.reg | |
| 36 echo "C:\\Users\\%USERNAME%\\AppData\\Local\\Sony\\"="1">> vegasuser.reg | |
| 37 echo.>> vegasuser.reg | |
| 38 echo [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Installer\UserData\S-1-5-18\Products\EEB0EEE18CB05E111AE90FD42AA3C585\InstallProperties]>> vegasuser.reg | |
| 39 echo "InstallSource"="C:\\Users\\Paper\\AppData\\Local\\Temp\\SonyInstall_1\\vegas130\\">>vegasuser.reg | |
| 40 echo.>> vegasuser.reg | |
| 41 echo [HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\{1EEE0BEE-0BC8-11E5-A19E-F04DA23A5C58}]>> vegasuser.reg | |
| 42 echo "InstallSource"="C:\\Users\\Paper\\AppData\\Local\\Temp\\SonyInstall_1\\vegas130\\">>vegasuser.reg | |
| 43 | |
| 44 reg.exe import "%~dp0\vegasuser.reg" | |
| 45 | |
| 46 pause | |
| 47 goto :eof | |
| 48 | |
| 49 :downloadfile | |
| 50 REM Downloads a file from a URL | |
| 51 REM Input 1 is the URL, input 2 is the file to output to | |
| 52 REM Compatible with PowerShell 2 | |
| 53 set "major=" | |
| 54 for /f "skip=3 delims=" %%i in ('powershell -Command "Get-Host | Select-Object Version"') do ( | |
| 55 if not defined major set "major=%%i" | |
| 56 ) | |
| 57 | |
| 58 if %major:~0,1% GEQ 2 ( | |
| 59 powershell -Command "& {$WebClient = New-Object System.Net.WebClient; $WebClient.DownloadFile('%~1', '%~2')}" | |
| 60 ) else ( | |
| 61 "%~dp0\bin\curl.exe" -o "%~2" "%~1" | |
| 62 ) | |
| 63 goto :eof |
