xcodeenv: Allow app names with with spaces in them

This commit is contained in:
Sander van der Burg 2013-02-12 11:35:21 +01:00
parent ec9c096e25
commit 5d6ffdb623

View File

@ -2,14 +2,14 @@
{name, app, device ? "iPhone", baseDir ? ""}:
stdenv.mkDerivation {
inherit name;
name = stdenv.lib.replaceChars [" "] [""] name;
buildCommand = ''
ensureDir $out/bin
cat > $out/bin/run-test-simulator << "EOF"
#! ${stdenv.shell} -e
cd ${app}/${baseDir}/${name}.app
"$(readlink "${xcodewrapper}/bin/iPhone Simulator")" -SimulateApplication ./${name} -SimulateDevice '${device}'
cd '${app}/${baseDir}/${name}.app'
"$(readlink "${xcodewrapper}/bin/iPhone Simulator")" -SimulateApplication './${name}' -SimulateDevice '${device}'
EOF
chmod +x $out/bin/run-test-simulator
'';