From 699ddc208f2f982c7bc008fbc21135b7dfedfbf0 Mon Sep 17 00:00:00 2001 From: xargon Date: Mon, 25 Jul 2022 21:01:45 +0200 Subject: [PATCH] Fixed a bug in the variables writing --- global.sh | 7 +++---- retrodeck.sh | 8 ++++---- 2 files changed, 7 insertions(+), 8 deletions(-) diff --git a/global.sh b/global.sh index 9083f5d5..5068bd14 100755 --- a/global.sh +++ b/global.sh @@ -11,7 +11,6 @@ conf_init() { echo "RetroDECK config file not found in $rd_conf" echo "Initializing" touch $rd_conf - read -p "Press enter to continue" #DEBUG # Variables to manage: adding a variable here means adding it to conf_write() echo "#!/bin/bash" >> $rd_conf @@ -25,7 +24,7 @@ conf_init() { echo "rdhome=$rdhome" >> $rd_conf # default roms folder location (internal) - roms_folder="$rdhome/roms" + roms_folder="$roms_folder" echo "roms_folder=$roms_folder" >> $rd_conf @@ -39,7 +38,7 @@ conf_init() { conf_write() { # writes the variables in the retrodeck config file - echo "Writing the config file" + echo "Writing the config file: $rd_conf" # TODO: this can be optimized with a while and a list of variables to check if [ ! -z "$version" ] #if the variable is not null then I update it @@ -54,7 +53,7 @@ conf_write() { if [ ! -z "$roms_folder" ] then - sed -i "s%rdhome=.*%rdhome=$roms_folder%" $rd_conf + sed -i "s%roms_folder=.*%roms_folder=$roms_folder%" $rd_conf fi } \ No newline at end of file diff --git a/retrodeck.sh b/retrodeck.sh index 17fb6a2e..0d8f9dbb 100644 --- a/retrodeck.sh +++ b/retrodeck.sh @@ -191,14 +191,14 @@ ra_init() { mv -fv $rdhome/bios/PPSSPP/flash0/font $rdhome/bios/PPSSPP/flash0/font.bak fi mkdir -p $rdhome/bios/PPSSPP - if [ ! -f "$rdhome/bios/PPSSPP/ppge_atlas.zim" ] - then + #if [ ! -f "$rdhome/bios/PPSSPP/ppge_atlas.zim" ] + #then wget "https://github.com/hrydgard/ppsspp/archive/refs/heads/master.zip" -P $rdhome/bios/PPSSPP unzip "$rdhome/bios/PPSSPP/master.zip" -d $rdhome/bios/PPSSPP/ - mv "$rdhome/bios/PPSSPP/ppsspp-master/assets"* "$rdhome/bios/PPSSPP/" + mv "$rdhome/bios/PPSSPP/ppsspp-master/assets/"* "$rdhome/bios/PPSSPP/" rm -rfv "$rdhome/bios/PPSSPP/master.zip" rm -rfv "$rdhome/bios/PPSSPP/ppsspp-master" - fi + #fi if [ -d $rdhome/bios/PPSSPP/flash0/font.bak ] then mv -fv $rdhome/bios/PPSSPP/flash0/font.bak $rdhome/bios/PPSSPP/flash0/font