-
-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Thorium XP - Installer #73
Comments
@Shine- I still need to do the 32 bit on 64 bit program files fix. As far as the .reg files go, yeah IDK how to do that. May have to just tell users to edit them using find and replace before installation. |
You could, for example, create the registry entries one by one using And, of course, optionally still provide the pre-written |
@Shine- I am much more good at bash than batch lol. How would I have the script dynamically get the drive letter and apply it to the registry entries needed? A really dirty approach would be to ship multiple versions of the .reg files, with different common drive letters like D: and E: in them lol. |
Since Windows doesn't have a See below for an example script that will read your predefined It would be much easier with VBS or PowerShell, but I wanted to keep this plain CMD. @echo off
set "pf=%programfiles:\=\\%"
if "%programfiles(x86)%" neq "" (
set "pf=%programfiles(x86):\=\\%"
)
echo Windows Registry Editor Version 5.00 > %temp%\thorium.reg
setlocal enabledelayedexpansion
for /f "skip=2 tokens=* delims= " %%n in (HKLM.reg HKCR.reg) do (
set "line=%%n"
set "line=!line:C:\\Program Files\\=%pf%\\!"
if "!line:~0,1!"=="[" echo.
echo !line!
) >> %temp%\thorium.reg
endlocal
start /wait regedit /s %temp%\thorium.reg
del %temp%\thorium.reg Use with caution, might still contain bugs... |
System Details
Problem
First of all, Kudos for the XP build!
Just 2 minor issues that you might want to take care of in the next release:
%programfiles%
instead of hardcodingC:\Program Files\Thorium
into the installer. This will help users who have their Windows installed on a different drive than C: (this was still possible in XP), and it will help users who are running localized Windows versions. You will, however, then have to figure something out how to handle the.reg
files (perhaps dynamically creating them from the installer.cmd
?) and how to handle it if someone installs the x86 build on a 64-Bit OS (that one is easy: if%programfiles(x86)%
exists, then you're on a 64-Bit OS)..reg
files are UNIX linefeeded (LF), instead of Windows (CRLF). Might not be a breaking issue, but XP Notepad didn't yet support LF, so it looks mangled when opening the.reg
files in Notepad.The text was updated successfully, but these errors were encountered: