From 10e80054bdbc9edf930cbc5c1f1285a20fe160ed Mon Sep 17 00:00:00 2001 From: Louie S Date: Sat, 6 Jan 2024 14:58:44 -0500 Subject: Fix method for checking and writing ROMPATH to desktop file --- rom-desktop-entry-generator.sh | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'rom-desktop-entry-generator.sh') diff --git a/rom-desktop-entry-generator.sh b/rom-desktop-entry-generator.sh index 01663b4..e53976e 100755 --- a/rom-desktop-entry-generator.sh +++ b/rom-desktop-entry-generator.sh @@ -39,9 +39,8 @@ build_desktop_file() { echo "Skipping: No configuration exists for SYSTEM" >> "$STDOUT_LOG" return fi - # FIXME this warning can have false positives - if [ ! -e "$ROMPATH" ]; then - echo "Warning: PATH does not exist" >> "$STDOUT_LOG" + if ! eval test -e "\"$ROMPATH\""; then + echo "Warning: PATH $ROMPATH does not exist" >> "$STDOUT_LOG" fi unset launcher @@ -54,7 +53,7 @@ build_desktop_file() { echo "Type=Application" >> "$OUTPUT" echo "Name=$NAME" >> "$OUTPUT" echo "Icon=${SCRIPTNAME}_${SYSTEM}_${NAME}" >> "$OUTPUT" - echo "Exec=$launcher $flags $ROMPATH" >> "$OUTPUT" + echo "Exec=$launcher $flags \"$ROMPATH\"" >> "$OUTPUT" echo "Categories=Game" >> "$OUTPUT" } -- cgit