Skip to content

Commit b050301

Browse files
committed
scummvm: don't hardcode the "extrapath" at runtime
In order to allow users to change the 'extrapath' directory, don't add the 'extrapath' parameter unless it's missing from the configuration file. Note that multiple 'extrapath' entries can be present in the configuration file, since it can be set per-game as well as a global option.
1 parent 31dc42c commit b050301

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

scriptmodules/emulators/scummvm.sh

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,10 @@ function configure_scummvm() {
8686
#!/bin/bash
8787
game="\$1"
8888
pushd "$romdir/scummvm" >/dev/null
89-
$md_inst/bin/scummvm --fullscreen --joystick=0 --extrapath="$md_inst/extra" "\$game"
89+
if ! grep -qs extrapath "\$HOME/.config/scummvm/scummvm.ini"; then
90+
params="--extrapath="$md_inst/extra""
91+
fi
92+
$md_inst/bin/scummvm --fullscreen \$params --joystick=0 "\$game"
9093
while read id desc; do
9194
echo "\$desc" > "$romdir/scummvm/\$id.svm"
9295
done < <($md_inst/bin/scummvm --list-targets | tail -n +3)

0 commit comments

Comments
 (0)