mirror of
https://github.com/RetroDECK/RetroDECK.git
synced 2024-11-22 05:55:38 +00:00
Clarify cooker reset wording
new start-rd-on-exit method for Configurator
This commit is contained in:
parent
9a9068db24
commit
26bf3f5dfc
|
@ -1 +1 @@
|
||||||
Subproject commit 78786102fc04cf104ef9bf2f0ebcacbdda357ae0
|
Subproject commit 0b1cfb79e591e10488a3262d6b38db843c39a409
|
|
@ -1 +1 @@
|
||||||
Subproject commit 50314360ded6fa3b9f0b602513b1164b7a6636ed
|
Subproject commit a2441b964afefd8cd1cebcdf562c7878670daf42
|
13
retrodeck.sh
13
retrodeck.sh
|
@ -47,9 +47,12 @@ https://retrodeck.net
|
||||||
cli_compress_all_games "$2"
|
cli_compress_all_games "$2"
|
||||||
;;
|
;;
|
||||||
--configurator*)
|
--configurator*)
|
||||||
launched_from_cli="true"
|
|
||||||
sh /app/tools/configurator.sh
|
sh /app/tools/configurator.sh
|
||||||
exit
|
if [[ $(configurator_generic_question_dialog "RetroDECK Configurator" "Would you like to launch RetroDECK after closing the Configurator?") == "false" ]]; then
|
||||||
|
exit
|
||||||
|
else
|
||||||
|
shift
|
||||||
|
fi
|
||||||
;;
|
;;
|
||||||
--reset-emulator*)
|
--reset-emulator*)
|
||||||
echo "You are about to reset one or more RetroDECK emulators."
|
echo "You are about to reset one or more RetroDECK emulators."
|
||||||
|
@ -104,16 +107,16 @@ if [ -f "$lockfile" ]; then
|
||||||
echo "Config file's version is $version but the actual version is $hard_version"
|
echo "Config file's version is $version but the actual version is $hard_version"
|
||||||
if grep -qF "cooker" <<< $hard_version; then # If newly-installed version is a "cooker" build
|
if grep -qF "cooker" <<< $hard_version; then # If newly-installed version is a "cooker" build
|
||||||
cooker_base_version=$(echo $hard_version | cut -d'-' -f2)
|
cooker_base_version=$(echo $hard_version | cut -d'-' -f2)
|
||||||
choice=$(zenity --icon-name=net.retrodeck.retrodeck --info --no-wrap --ok-label="Upgrade" --extra-button="Don't Upgrade" --extra-button="Fresh Install" \
|
choice=$(zenity --icon-name=net.retrodeck.retrodeck --info --no-wrap --ok-label="Upgrade" --extra-button="Don't Upgrade" --extra-button="Full Wipe and Fresh Install" \
|
||||||
--window-icon="/app/share/icons/hicolor/scalable/apps/net.retrodeck.retrodeck.svg" \
|
--window-icon="/app/share/icons/hicolor/scalable/apps/net.retrodeck.retrodeck.svg" \
|
||||||
--title "RetroDECK Cooker Upgrade" \
|
--title "RetroDECK Cooker Upgrade" \
|
||||||
--text="You appear to be upgrading to a \"cooker\" build of RetroDECK.\n\nWould you like to perform the standard post-update process, skip the post-update process or remove ALL existing RetroDECK data to start from a fresh install?\n\nPerforming the normal post-update process multiple times may lead to unexpected results.")
|
--text="You appear to be upgrading to a \"cooker\" build of RetroDECK.\n\nWould you like to perform the standard post-update process, skip the post-update process or remove ALL existing RetroDECK folders and data (including ROMs and saves) to start from a fresh install?\n\nPerforming the normal post-update process multiple times may lead to unexpected results.")
|
||||||
rc=$? # Capture return code, as "Yes" button has no text value
|
rc=$? # Capture return code, as "Yes" button has no text value
|
||||||
if [[ $rc == "1" ]]; then # If any button other than "Yes" was clicked
|
if [[ $rc == "1" ]]; then # If any button other than "Yes" was clicked
|
||||||
if [[ $choice == "Don't Upgrade" ]]; then # If user wants to bypass the post_update.sh process this time.
|
if [[ $choice == "Don't Upgrade" ]]; then # If user wants to bypass the post_update.sh process this time.
|
||||||
echo "Skipping upgrade process for cooker build, updating stored version in retrodeck.cfg"
|
echo "Skipping upgrade process for cooker build, updating stored version in retrodeck.cfg"
|
||||||
set_setting_value $rd_conf "version" "$hard_version" retrodeck # Set version of currently running RetroDECK to updated retrodeck.cfg
|
set_setting_value $rd_conf "version" "$hard_version" retrodeck # Set version of currently running RetroDECK to updated retrodeck.cfg
|
||||||
elif [[ $choice == "Fresh Install" ]]; then # Remove all RetroDECK data and start a fresh install
|
elif [[ $choice == "Full Wipe and Fresh Install" ]]; then # Remove all RetroDECK data and start a fresh install
|
||||||
echo "Removing RetroDECK data and starting fresh"
|
echo "Removing RetroDECK data and starting fresh"
|
||||||
rm -rf /var
|
rm -rf /var
|
||||||
rm -rf "$HOME/retrodeck"
|
rm -rf "$HOME/retrodeck"
|
||||||
|
|
|
@ -1289,22 +1289,6 @@ configurator_usb_import_dialog() {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
# Functions to run at exit, without keeping Configurator running in background
|
|
||||||
|
|
||||||
launch_retrodeck_after_configurator_close() {
|
|
||||||
if [[ $(check_desktop_mode) == "true" && "$launched_from_cli" == "true" ]]; then
|
|
||||||
if [[ $(configurator_generic_question_dialog "RetroDECK Configurator" "Would you like to launch RetroDECK after closing the Configurator?") == "true" ]]; then
|
|
||||||
start_retrodeck
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
trap 'launch_retrodeck_after_configurator_close' EXIT
|
|
||||||
|
|
||||||
# START THE CONFIGURATOR
|
# START THE CONFIGURATOR
|
||||||
|
|
||||||
if [[ "$1" == "cli" ]]; then
|
|
||||||
launched_from_cli="true"
|
|
||||||
fi
|
|
||||||
|
|
||||||
configurator_welcome_dialog
|
configurator_welcome_dialog
|
||||||
|
|
Loading…
Reference in a new issue