mirror of
https://github.com/RetroDECK/RetroDECK.git
synced 2024-11-25 15:35:38 +00:00
More setting retention fixes
This commit is contained in:
parent
9fa49ff904
commit
9e50cdf4a8
30
retrodeck.sh
30
retrodeck.sh
|
@ -95,8 +95,10 @@ standalones_init() {
|
||||||
# configuring Yuzu
|
# configuring Yuzu
|
||||||
dir_prep "$rdhome/.logs/yuzu" "/var/data/yuzu/log"
|
dir_prep "$rdhome/.logs/yuzu" "/var/data/yuzu/log"
|
||||||
mkdir -pv /var/config/yuzu/
|
mkdir -pv /var/config/yuzu/
|
||||||
|
if [ $overwrite_configs = true ]; then # Initializing config after major version update
|
||||||
cp -fvr $emuconfigs/yuzu/* /var/config/yuzu/
|
cp -fvr $emuconfigs/yuzu/* /var/config/yuzu/
|
||||||
sed -i 's#~/retrodeck#'$rdhome'#g' /var/config/yuzu/qt-config.ini
|
sed -i 's#~/retrodeck#'$rdhome'#g' /var/config/yuzu/qt-config.ini
|
||||||
|
fi
|
||||||
dir_prep "$rdhome/screenshots" "/var/data/yuzu/screenshots"
|
dir_prep "$rdhome/screenshots" "/var/data/yuzu/screenshots"
|
||||||
|
|
||||||
# Dolphin
|
# Dolphin
|
||||||
|
@ -104,8 +106,10 @@ standalones_init() {
|
||||||
echo "Initializing DOLPHIN"
|
echo "Initializing DOLPHIN"
|
||||||
echo "----------------------"
|
echo "----------------------"
|
||||||
mkdir -pv /var/config/dolphin-emu/
|
mkdir -pv /var/config/dolphin-emu/
|
||||||
|
if [ $overwrite_configs = true ]; then # Initializing config after major version update
|
||||||
cp -fvr "$emuconfigs/dolphin/"* /var/config/dolphin-emu/
|
cp -fvr "$emuconfigs/dolphin/"* /var/config/dolphin-emu/
|
||||||
sed -i 's#~/retrodeck#'$rdhome'#g' /var/config/dolphin-emu/Dolphin.ini
|
sed -i 's#~/retrodeck#'$rdhome'#g' /var/config/dolphin-emu/Dolphin.ini
|
||||||
|
fi
|
||||||
dir_prep "$rdhome/saves/gc/dolphin/EUR" "/var/data/dolphin-emu/GC/EUR"
|
dir_prep "$rdhome/saves/gc/dolphin/EUR" "/var/data/dolphin-emu/GC/EUR"
|
||||||
dir_prep "$rdhome/saves/gc/dolphin/USA" "/var/data/dolphin-emu/GC/USA"
|
dir_prep "$rdhome/saves/gc/dolphin/USA" "/var/data/dolphin-emu/GC/USA"
|
||||||
dir_prep "$rdhome/saves/gc/dolphin/JAP" "/var/data/dolphin-emu/GC/JAP"
|
dir_prep "$rdhome/saves/gc/dolphin/JAP" "/var/data/dolphin-emu/GC/JAP"
|
||||||
|
@ -120,9 +124,11 @@ standalones_init() {
|
||||||
mkdir -pv "/var/config/PCSX2/inis"
|
mkdir -pv "/var/config/PCSX2/inis"
|
||||||
mkdir -pv "$rdhome/saves/ps2/pcsx2/memcards"
|
mkdir -pv "$rdhome/saves/ps2/pcsx2/memcards"
|
||||||
mkdir -pv "$rdhome/states/ps2/pcsx2"
|
mkdir -pv "$rdhome/states/ps2/pcsx2"
|
||||||
|
if [ $overwrite_configs = true ]; then # Initializing config after major version update
|
||||||
cp -fvr $emuconfigs/PCSX2/* /var/config/PCSX2/inis/
|
cp -fvr $emuconfigs/PCSX2/* /var/config/PCSX2/inis/
|
||||||
sed -i 's#~/retrodeck#'$rdhome'#g' /var/config/PCSX2/inis/PCSX2_ui.ini
|
sed -i 's#~/retrodeck#'$rdhome'#g' /var/config/PCSX2/inis/PCSX2_ui.ini
|
||||||
sed -i 's#~/retrodeck#'$rdhome'#g' /var/config/PCSX2/inis/PCSX2.ini
|
sed -i 's#~/retrodeck#'$rdhome'#g' /var/config/PCSX2/inis/PCSX2.ini
|
||||||
|
fi
|
||||||
#dir_prep "$rdhome/states/ps2/pcsx2" "/var/config/PCSX2/sstates"
|
#dir_prep "$rdhome/states/ps2/pcsx2" "/var/config/PCSX2/sstates"
|
||||||
#dir_prep "$rdhome/screenshots" "/var/config/PCSX2/snaps"
|
#dir_prep "$rdhome/screenshots" "/var/config/PCSX2/snaps"
|
||||||
#dir_prep "$rdhome/.logs" "/var/config/PCSX2/logs"
|
#dir_prep "$rdhome/.logs" "/var/config/PCSX2/logs"
|
||||||
|
@ -136,9 +142,11 @@ standalones_init() {
|
||||||
mkdir -pv "$rdhome/saves/nds/melonds"
|
mkdir -pv "$rdhome/saves/nds/melonds"
|
||||||
mkdir -pv "$rdhome/states/nds/melonds"
|
mkdir -pv "$rdhome/states/nds/melonds"
|
||||||
dir_prep "$rdhome/bios" "/var/config/melonDS/bios"
|
dir_prep "$rdhome/bios" "/var/config/melonDS/bios"
|
||||||
|
if [ $overwrite_configs = true ]; then # Initializing config after major version update
|
||||||
cp -fvr $emuconfigs/melonDS.ini /var/config/melonDS/
|
cp -fvr $emuconfigs/melonDS.ini /var/config/melonDS/
|
||||||
# Replace ~/retrodeck with $rdhome as ~ cannot be understood by MelonDS
|
# Replace ~/retrodeck with $rdhome as ~ cannot be understood by MelonDS
|
||||||
sed -i 's#~/retrodeck#'$rdhome'#g' /var/config/melonDS/melonDS.ini
|
sed -i 's#~/retrodeck#'$rdhome'#g' /var/config/melonDS/melonDS.ini
|
||||||
|
fi
|
||||||
|
|
||||||
# CITRA
|
# CITRA
|
||||||
echo "------------------------"
|
echo "------------------------"
|
||||||
|
@ -149,8 +157,10 @@ standalones_init() {
|
||||||
mkdir -pv "$rdhome/saves/n3ds/citra/sdmc/"
|
mkdir -pv "$rdhome/saves/n3ds/citra/sdmc/"
|
||||||
dir_prep "$rdhome/bios/citra/sysdata" "/var/data/citra-emu/sysdata"
|
dir_prep "$rdhome/bios/citra/sysdata" "/var/data/citra-emu/sysdata"
|
||||||
dir_prep "$rdhome/.logs/citra" "/var/data/citra-emu/log"
|
dir_prep "$rdhome/.logs/citra" "/var/data/citra-emu/log"
|
||||||
|
if [ $overwrite_configs = true ]; then # Initializing config after major version update
|
||||||
cp -fv $emuconfigs/citra-qt-config.ini /var/config/citra-emu/qt-config.ini
|
cp -fv $emuconfigs/citra-qt-config.ini /var/config/citra-emu/qt-config.ini
|
||||||
sed -i 's#~/retrodeck#'$rdhome'#g' /var/config/citra-emu/qt-config.ini
|
sed -i 's#~/retrodeck#'$rdhome'#g' /var/config/citra-emu/qt-config.ini
|
||||||
|
fi
|
||||||
#TODO: do the same with roms folders after new variables is pushed (check even the others qt-emu)
|
#TODO: do the same with roms folders after new variables is pushed (check even the others qt-emu)
|
||||||
#But actually everything is always symlinked to retrodeck/roms so it might be not needed
|
#But actually everything is always symlinked to retrodeck/roms so it might be not needed
|
||||||
#sed -i 's#~/retrodeck#'$rdhome'#g' /var/config/citra-emu/qt-config.ini
|
#sed -i 's#~/retrodeck#'$rdhome'#g' /var/config/citra-emu/qt-config.ini
|
||||||
|
@ -160,16 +170,20 @@ standalones_init() {
|
||||||
echo "Initializing RPCS3"
|
echo "Initializing RPCS3"
|
||||||
echo "------------------------"
|
echo "------------------------"
|
||||||
mkdir -pv /var/config/rpcs3/
|
mkdir -pv /var/config/rpcs3/
|
||||||
|
if [ $overwrite_configs = true ]; then # Initializing config after major version update
|
||||||
cp -fvr $emuconfigs/rpcs3/* /var/config/rpcs3/
|
cp -fvr $emuconfigs/rpcs3/* /var/config/rpcs3/
|
||||||
sed -i 's#/home/deck/retrodeck#'$rdhome'#g' /var/config/rpcs3/vfs.yml
|
sed -i 's#/home/deck/retrodeck#'$rdhome'#g' /var/config/rpcs3/vfs.yml
|
||||||
|
fi
|
||||||
|
|
||||||
# XEMU
|
# XEMU
|
||||||
echo "------------------------"
|
echo "------------------------"
|
||||||
echo "Initializing XEMU"
|
echo "Initializing XEMU"
|
||||||
echo "------------------------"
|
echo "------------------------"
|
||||||
mkdir -pv $rdhome/saves/xbox/xemu/
|
mkdir -pv $rdhome/saves/xbox/xemu/
|
||||||
|
if [ $overwrite_configs = true ]; then # Initializing config after major version update
|
||||||
cp -fv $emuconfigs/xemu.toml /var/data/xemu/xemu.toml
|
cp -fv $emuconfigs/xemu.toml /var/data/xemu/xemu.toml
|
||||||
sed -i 's#/home/deck/retrodeck#'$rdhome'#g' /var/data/xemu/xemu.toml
|
sed -i 's#/home/deck/retrodeck#'$rdhome'#g' /var/data/xemu/xemu.toml
|
||||||
|
fi
|
||||||
# Preparing HD dummy Image if the image is not found
|
# Preparing HD dummy Image if the image is not found
|
||||||
if [ ! -f $rdhome/bios/xbox_hdd.qcow2 ]
|
if [ ! -f $rdhome/bios/xbox_hdd.qcow2 ]
|
||||||
then
|
then
|
||||||
|
@ -183,16 +197,20 @@ standalones_init() {
|
||||||
echo "Initializing PPSSPPSDL"
|
echo "Initializing PPSSPPSDL"
|
||||||
echo "------------------------"
|
echo "------------------------"
|
||||||
mkdir -p /var/config/ppsspp/PSP/SYSTEM/
|
mkdir -p /var/config/ppsspp/PSP/SYSTEM/
|
||||||
|
if [ $overwrite_configs = true ]; then # Initializing config after major version update
|
||||||
cp -fv $emuconfigs/ppssppsdl/* /var/config/ppsspp/PSP/SYSTEM/
|
cp -fv $emuconfigs/ppssppsdl/* /var/config/ppsspp/PSP/SYSTEM/
|
||||||
sed -i 's#/home/deck/retrodeck#'$rdhome'#g' /var/config/ppsspp/PSP/SYSTEM/ppsspp.ini
|
sed -i 's#/home/deck/retrodeck#'$rdhome'#g' /var/config/ppsspp/PSP/SYSTEM/ppsspp.ini
|
||||||
|
fi
|
||||||
|
|
||||||
# DUCKSTATION
|
# DUCKSTATION
|
||||||
echo "------------------------"
|
echo "------------------------"
|
||||||
echo "Initializing DUCKSTATION"
|
echo "Initializing DUCKSTATION"
|
||||||
echo "------------------------"
|
echo "------------------------"
|
||||||
mkdir -p /var/config/duckstation/
|
mkdir -p /var/config/duckstation/
|
||||||
|
if [ $overwrite_configs = true ]; then # Initializing config after major version update
|
||||||
cp -fv $emuconfigs/duckstation/* /var/config/duckstation
|
cp -fv $emuconfigs/duckstation/* /var/config/duckstation
|
||||||
sed -i 's#/home/deck/retrodeck/bios#'$rdhome/bios'#g' /var/config/ppsspp/PSP/SYSTEM/settings.ini
|
sed -i 's#/home/deck/retrodeck/bios#'$rdhome/bios'#g' /var/config/ppsspp/PSP/SYSTEM/settings.ini
|
||||||
|
if [ $overwrite_configs = true ]; then # Initializing config after major version update
|
||||||
|
|
||||||
|
|
||||||
# PICO-8
|
# PICO-8
|
||||||
|
@ -204,9 +222,9 @@ ra_init() {
|
||||||
dir_prep "$rdhome/bios" "/var/config/retroarch/system"
|
dir_prep "$rdhome/bios" "/var/config/retroarch/system"
|
||||||
dir_prep "$rdhome/.logs/retroarch" "/var/config/retroarch/logs"
|
dir_prep "$rdhome/.logs/retroarch" "/var/config/retroarch/logs"
|
||||||
mkdir -pv /var/config/retroarch/cores/
|
mkdir -pv /var/config/retroarch/cores/
|
||||||
cp /app/share/libretro/cores/* /var/config/retroarch/cores/
|
cp -fv /app/share/libretro/cores/* /var/config/retroarch/cores/
|
||||||
cp -fv $emuconfigs/retroarch.cfg /var/config/retroarch/
|
|
||||||
if [ $overwrite_configs = true ]; then
|
if [ $overwrite_configs = true ]; then
|
||||||
|
cp -fv $emuconfigs/retroarch.cfg /var/config/retroarch/
|
||||||
cp -fv $emuconfigs/retroarch-core-options.cfg /var/config/retroarch/
|
cp -fv $emuconfigs/retroarch-core-options.cfg /var/config/retroarch/
|
||||||
sed -i 's#~/retrodeck#'$rdhome'#g' /var/config/retroarch/retroarch.cfg
|
sed -i 's#~/retrodeck#'$rdhome'#g' /var/config/retroarch/retroarch.cfg
|
||||||
fi
|
fi
|
||||||
|
@ -607,11 +625,15 @@ finit() {
|
||||||
# PICO-8
|
# PICO-8
|
||||||
dir_prep "$roms_folder/pico8" "$rdhome/bios/pico8/bbs/carts" #this is the folder where pico-8 is saving the carts
|
dir_prep "$roms_folder/pico8" "$rdhome/bios/pico8/bbs/carts" #this is the folder where pico-8 is saving the carts
|
||||||
|
|
||||||
|
overwrite_configs=true
|
||||||
|
|
||||||
ra_init
|
ra_init
|
||||||
standalones_init
|
standalones_init
|
||||||
tools_init
|
tools_init
|
||||||
create_lock
|
create_lock
|
||||||
|
|
||||||
|
overwrite_configs=false
|
||||||
|
|
||||||
zenity --icon-name=net.retrodeck.retrodeck --info --no-wrap \
|
zenity --icon-name=net.retrodeck.retrodeck --info --no-wrap \
|
||||||
--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" \
|
--title "RetroDECK" \
|
||||||
|
@ -658,11 +680,15 @@ https://retrodeck.net
|
||||||
exit
|
exit
|
||||||
;;
|
;;
|
||||||
--reset-ra*)
|
--reset-ra*)
|
||||||
|
overwrite_configs=true
|
||||||
ra_init
|
ra_init
|
||||||
|
overwrite_configs=false
|
||||||
shift # past argument with no value
|
shift # past argument with no value
|
||||||
;;
|
;;
|
||||||
--reset-sa*)
|
--reset-sa*)
|
||||||
|
overwrite_configs=true
|
||||||
standalones_init
|
standalones_init
|
||||||
|
overwrite_configs=false
|
||||||
shift # past argument with no value
|
shift # past argument with no value
|
||||||
;;
|
;;
|
||||||
--reset-tools*)
|
--reset-tools*)
|
||||||
|
|
Loading…
Reference in a new issue