forked from CastroFidel/PortWINE
Scripts version 2294
This commit is contained in:
@ -1204,12 +1204,37 @@ pw_init_db () {
|
||||
PW_PREFIX_NAME=$(echo "${portwine_exe}" | awk -F"/prefixes/" '{print $2}' | awk -F"/" '{print $1}')
|
||||
fi
|
||||
fi
|
||||
|
||||
if [[ -f "${PORTWINE_DB_FILE}" ]] ; then
|
||||
# shellcheck source=/dev/null
|
||||
source "${PORTWINE_DB_FILE}"
|
||||
init_wine_ver &&
|
||||
print_info "Use $PORTWINE_DB_FILE db file."
|
||||
else
|
||||
if [[ "${PW_DISABLED_CREATE_DB}" != 1 ]] ; then
|
||||
if [[ ! -z "${PORTWINE_DB}" ]] ; then
|
||||
export PORTWINE_DB_FILE=$(grep -il "\#${PORTWINE_DB}.exe" "${PORT_SCRIPTS_PATH}/portwine_db"/*)
|
||||
if [[ -z "${PORTWINE_DB_FILE}" ]] ; then
|
||||
{
|
||||
echo "#!/usr/bin/env bash"
|
||||
echo "#Author: ${USER}"
|
||||
echo "#${PORTWINE_DB}.exe"
|
||||
echo "#Rating=1-5"
|
||||
} > "${portwine_exe}".ppdb
|
||||
export PORTWINE_DB_FILE="${portwine_exe}".ppdb
|
||||
fi
|
||||
if [[ ! -z $(echo "${portwine_exe}" | grep "/data/prefixes/") ]] && \
|
||||
[[ -z $(echo "${portwine_exe}" | grep "/data/prefixes/DEFAULT/") ]]
|
||||
then
|
||||
PW_PREFIX_NAME=$(echo "${portwine_exe}" | awk -F"/prefixes/" '{print $2}' | awk -F"/" '{print $1}')
|
||||
fi
|
||||
# shellcheck source=/dev/null
|
||||
source "${PORTWINE_DB_FILE}"
|
||||
fi
|
||||
edit_db_from_gui PW_VULKAN_USE PW_WINE_USE PW_PREFIX_NAME
|
||||
fi
|
||||
fi
|
||||
|
||||
if [[ -z "${PATH_TO_GAME}" ]] || [[ ! -d "${PATH_TO_GAME}" ]]; then
|
||||
PATH_TO_GAME="$( cd "$( dirname "${portwine_exe}" )" >/dev/null 2>&1 && pwd )"
|
||||
export PATH_TO_GAME
|
||||
@ -1240,30 +1265,6 @@ pw_init_db () {
|
||||
fi
|
||||
done
|
||||
fi
|
||||
if [[ "${PW_DISABLED_CREATE_DB}" != 1 ]] ; then
|
||||
if [[ ! -z "${PORTWINE_DB}" ]] \
|
||||
&& [[ -z "${PORTWINE_DB_FILE}" ]]
|
||||
then
|
||||
PORTWINE_DB_FILE=$(grep -il "\#${PORTWINE_DB}.exe" "${PORT_SCRIPTS_PATH}/portwine_db"/*)
|
||||
if [[ -z "${PORTWINE_DB_FILE}" ]] ; then
|
||||
{
|
||||
echo "#!/usr/bin/env bash"
|
||||
echo "#Author: ${USER}"
|
||||
echo "#${PORTWINE_DB}.exe"
|
||||
echo "#Rating=1-5"
|
||||
} > "${portwine_exe}".ppdb
|
||||
export PORTWINE_DB_FILE="${portwine_exe}".ppdb
|
||||
fi
|
||||
if [[ ! -z $(echo "${portwine_exe}" | grep "/data/prefixes/") ]] && \
|
||||
[[ -z $(echo "${portwine_exe}" | grep "/data/prefixes/DEFAULT/") ]]
|
||||
then
|
||||
PW_PREFIX_NAME=$(echo "${portwine_exe}" | awk -F"/prefixes/" '{print $2}' | awk -F"/" '{print $1}')
|
||||
fi
|
||||
# shellcheck source=/dev/null
|
||||
source "${PORTWINE_DB_FILE}"
|
||||
fi
|
||||
edit_db_from_gui PW_VULKAN_USE PW_WINE_USE PW_PREFIX_NAME
|
||||
fi
|
||||
fi
|
||||
|
||||
[[ "${START_FROM_STEAM}" == 1 ]] && export PW_GUI_DISABLED_CS=1
|
||||
|
@ -617,6 +617,9 @@ case "${VULKAN_MOD}" in
|
||||
esac
|
||||
|
||||
init_wine_ver
|
||||
if [[ -f "${PORTWINE_DB_FILE}" ]] ; then
|
||||
edit_db_from_gui PW_VULKAN_USE PW_WINE_USE PW_PREFIX_NAME
|
||||
fi
|
||||
|
||||
[[ ! -z "$PW_YAD_SET" ]] && case "$PW_YAD_SET" in
|
||||
98) portwine_delete_shortcut ;;
|
||||
|
@ -1,6 +1,6 @@
|
||||
#!/usr/bin/env bash
|
||||
#Author: Castro-Fidel (linux-gaming.ru)
|
||||
#SCRIPTS_NEXT_VERSION=2293
|
||||
#SCRIPTS_NEXT_VERSION=2294
|
||||
########################################################################
|
||||
export LANGUAGES_LIST="ru"
|
||||
export PW_MANGOHUD="0"
|
||||
|
Reference in New Issue
Block a user