From af62974fdb1487e229090d2f6c0712cb1a5044a5 Mon Sep 17 00:00:00 2001 From: Mikhail Tergoev Date: Thu, 31 Oct 2024 18:46:55 +0300 Subject: [PATCH] fix download no-mirror and drop progpfx --- data_from_portwine/scripts/functions_helper | 11 +++++------ data_from_portwine/scripts/start.sh | 1 - data_from_portwine/scripts/var | 2 -- 3 files changed, 5 insertions(+), 9 deletions(-) diff --git a/data_from_portwine/scripts/functions_helper b/data_from_portwine/scripts/functions_helper index 54f560ee..bf6afe88 100755 --- a/data_from_portwine/scripts/functions_helper +++ b/data_from_portwine/scripts/functions_helper @@ -541,7 +541,7 @@ try_download () { if [[ -n "${PW_AUTOINSTALL_EXE}" ]] \ && [[ "$no_mirror" == "true" ]] then - filename="$(basename "${PW_AUTOINSTALL_EXE}")" + filename="${PW_AUTOINSTALL_EXE//*\//}" else filename="$(basename "$1")" fi @@ -575,8 +575,8 @@ try_download () { else curl -f -# -A 'Mozilla/5.0 (compatible; Konqueror/2.1.1; X11)' -H 'Cache-Control: no-cache, no-store' \ -H 'Pragma: no-cache' -L ${FIRST_URL[@]} -o "$dest" 2>&1 | \ - tr '\r' '\n' | sed -ur 's|[# ]+||g;s|.*=.*||g;s|.*|#Downloading at &\n&|g' | \ - "$pw_yad" --progress --pulsate --text="${translations[Downloading]} $filename" --auto-close --no-escape \ + tr '\r' '\n' | sed -ur 's|[# ]+||g;s|100||g;s|.*=.*||g;s|.*|#Downloading at &\n&|g' | \ + "$pw_yad" --progress --text="${translations[Downloading]} $filename" --auto-close --no-escape \ --auto-kill --text-align="center" --fixed --no-buttons --title "PortProton" --width=500 --height=90 \ --window-icon="$PW_GUI_ICON_PATH/portproton.svg" --borders="$PROGRESS_BAR_BORDERS_SIZE" fi @@ -586,8 +586,8 @@ try_download () { print_warning "Failed download $filename from ${FIRST_URL[0]}, trying mirror: ${SECOND_URL[0]}" curl -f -# -A 'Mozilla/5.0 (compatible; Konqueror/2.1.1; X11)' -H 'Cache-Control: no-cache, no-store' \ -H 'Pragma: no-cache' -L ${SECOND_URL[@]} -o "$dest" 2>&1 | \ - tr '\r' '\n' | sed -ur 's|[# ]+||g;s|.*=.*||g;s|.*|#Downloading at &\n&|g' | \ - "$pw_yad" --progress --pulsate --text="${translations[Downloading]} $filename" --auto-close --no-escape \ + tr '\r' '\n' | sed -ur 's|[# ]+||g;s|100||g;s|.*=.*||g;s|.*|#Downloading at &\n&|g' | \ + "$pw_yad" --progress --text="${translations[Downloading]} $filename" --auto-close --no-escape \ --auto-kill --text-align="center" --fixed --no-buttons --title "PortProton" --width=500 --height=90 \ --window-icon="$PW_GUI_ICON_PATH/portproton.svg" --borders="$PROGRESS_BAR_BORDERS_SIZE" fi @@ -2750,7 +2750,6 @@ start_portwine () { pw_get_pfx () { case "${PW_PREFIX_NAME}" in - PROGRAMS) local FILE_NAME_PFX="progpfx${PROGPFX_VER}" ;; DOTNET) local FILE_NAME_PFX="dotpfx${DOTPFX_VER}" ;; *) return 0 ;; esac diff --git a/data_from_portwine/scripts/start.sh b/data_from_portwine/scripts/start.sh index ee9d5c53..7de62851 100755 --- a/data_from_portwine/scripts/start.sh +++ b/data_from_portwine/scripts/start.sh @@ -128,7 +128,6 @@ popd 1>/dev/null || fatal create_new_dir "${PORT_WINE_PATH}/data/prefixes/DEFAULT" create_new_dir "${PORT_WINE_PATH}/data/prefixes/DOTNET" -create_new_dir "${PORT_WINE_PATH}/data/prefixes/PROGRAMS" try_force_link_dir "${PORT_WINE_PATH}/data/prefixes" "${PORT_WINE_PATH}" pushd "${PORT_WINE_PATH}/data/prefixes/" 1>/dev/null || fatal diff --git a/data_from_portwine/scripts/var b/data_from_portwine/scripts/var index 9541affe..e04a701e 100755 --- a/data_from_portwine/scripts/var +++ b/data_from_portwine/scripts/var @@ -134,7 +134,6 @@ export PW_GS_MANGOAPP="0" ###PREFIX_VERSION### export DOTPFX_VER="48v7" export DEFPFX_VER="v1" -export PROGPFX_VER="v1" export PW_MUST_WINEDLLOVERRIDES="steam_api,steam_api64,steamclient,steamclient64=n;dotnetfx35.exe,dotnetfx35setup.exe=b;winemenubuilder.exe=" ################################################################# # Get our APi on https://www.steamgriddb.com/profile/preferences/api/ @@ -148,7 +147,6 @@ pw_list_install_dll_in_prefix () case $PW_PREFIX_NAME in DEFAULT) export PW_MUST_HAVE_DLL="$STANDART_DLL" ;; DOTNET) export PW_MUST_HAVE_DLL="dotnet48" ;; - PROGRAMS) export PW_MUST_HAVE_DLL="riched20 msxml3 msxml4 msxml6" ;; *) export PW_MUST_HAVE_DLL="sandbox" ;; esac }