mirror of
https://github.com/RetroDECK/RetroDECK.git
synced 2025-02-16 19:35:39 +00:00
Create file only if does not exists + fixed syntax
This commit is contained in:
parent
ec1f9a0305
commit
4c2e555812
|
@ -76,6 +76,9 @@ add_to_steam() {
|
||||||
log d "Sanitized Name: $sanitized_name"
|
log d "Sanitized Name: $sanitized_name"
|
||||||
|
|
||||||
local launcher="$steamsync_folder/${sanitized_name}.sh"
|
local launcher="$steamsync_folder/${sanitized_name}.sh"
|
||||||
|
|
||||||
|
if [ ! -e $launcher ]; then
|
||||||
|
|
||||||
log d "Creating desktop file: $launcher"
|
log d "Creating desktop file: $launcher"
|
||||||
|
|
||||||
# if [[ -v command_list_default[$system] ]]; then
|
# if [[ -v command_list_default[$system] ]]; then
|
||||||
|
@ -103,16 +106,19 @@ add_to_steam() {
|
||||||
# EOF
|
# EOF
|
||||||
cat <<EOF > "$launcher"
|
cat <<EOF > "$launcher"
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
if [ test "$(whereis flatpak)" = "flatpak:" ]; then
|
if [ test "\$(whereis flatpak)" = "flatpak:" ]; then
|
||||||
flatpak-spawn --host $command
|
flatpak-spawn --host $command
|
||||||
else
|
else
|
||||||
$command
|
$command
|
||||||
fi
|
fi
|
||||||
EOF
|
EOF
|
||||||
|
else
|
||||||
|
log d "$launcher desktop file already exists"
|
||||||
|
fi
|
||||||
done
|
done
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
steam-rom-manager add
|
#steam-rom-manager add
|
||||||
log i "Steam Sync: completed"
|
log i "Steam Sync: completed"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue