Create registry key that prevents wine file associations

This commit is contained in:
the-sane 2024-09-20 11:35:44 -04:00
parent 78a98f24a7
commit 7a0c85431a

View File

@ -2564,14 +2564,19 @@ install_game_wine() {
# Create a temporary log file # Create a temporary log file
tmp_install_log="$(mktemp --suffix=".log" -t "lughelper-install-XXX")" tmp_install_log="$(mktemp --suffix=".log" -t "lughelper-install-XXX")"
# Run the installer # Create the new prefix
export WINEPREFIX="$install_dir" export WINEPREFIX="$install_dir"
debug_print continue "Preparing the wine prefix..." debug_print continue "Preparing the wine prefix..."
winecfg -v win11 >"$tmp_install_log" 2>&1 && winecfg -v win11 >"$tmp_install_log" 2>&1 &&
# Add registry key that prevents wine from creating unnecessary file type associations
wine reg add "HKEY_CURRENT_USER\Software\Wine\FileOpenAssociations" /v Enable /d N >"$tmp_install_log" 2>&1
# Install powershell
debug_print continue "Installing dxvk and powershell, please wait..." debug_print continue "Installing dxvk and powershell, please wait..."
winetricks dxvk powershell >>"$tmp_install_log" 2>&1 winetricks dxvk powershell >>"$tmp_install_log" 2>&1
# Run the installer
debug_print continue "Installing the launcher, please wait..." debug_print continue "Installing the launcher, please wait..."
wine "$tmp_dir/$rsi_installer" /S >>"$tmp_install_log" 2>&1 wine "$tmp_dir/$rsi_installer" /S >>"$tmp_install_log" 2>&1