just keep all the compile/mv stuff in one script

This commit is contained in:
Corey Johnson 2011-08-23 16:20:12 -07:00
parent 89390b3015
commit 3d8545bbb0
2 changed files with 10 additions and 5 deletions

View File

@ -189,7 +189,7 @@
8D1107290486CEB800E47090 /* Resources */,
8D11072C0486CEB800E47090 /* Sources */,
8D11072E0486CEB800E47090 /* Frameworks */,
8393439613FE480600EF93FB /* Copy HTML folder to bundle and compile CoffeeScript */,
8393439613FE480600EF93FB /* Copy HTML folder & compile CoffeeScript */,
);
buildRules = (
);
@ -240,19 +240,19 @@
/* End PBXResourcesBuildPhase section */
/* Begin PBXShellScriptBuildPhase section */
8393439613FE480600EF93FB /* Copy HTML folder to bundle and compile CoffeeScript */ = {
8393439613FE480600EF93FB /* Copy HTML folder & compile CoffeeScript */ = {
isa = PBXShellScriptBuildPhase;
buildActionMask = 2147483647;
files = (
);
inputPaths = (
);
name = "Copy HTML folder to bundle and compile CoffeeScript";
name = "Copy HTML folder & compile CoffeeScript";
outputPaths = (
);
runOnlyForDeploymentPostprocessing = 0;
shellPath = /bin/sh;
shellScript = "\"$PROJECT_DIR/script/compile.sh\"\n\"$PROJECT_DIR/script/copy-html.sh\"";
shellScript = "\"$PROJECT_DIR/script/compile.sh\"";
showEnvVarsInLog = 0;
};
/* End PBXShellScriptBuildPhase section */

View File

@ -1,5 +1,10 @@
#!/bin/sh
SOURCE_SCRIPTS_DIR="$PROJECT_DIR/HTML"
DESTINATION_SCRIPTS_DIR="$BUILT_PRODUCTS_DIR/$CONTENTS_FOLDER_PATH/Resources/"
PATH="$PATH:/usr/local/bin/"
hash coffee 2>&- || { echo >&2 "error: Coffee is required but it's not installed (http://jashkenas.github.com/coffee-script/)."; exit 1; }
coffee -o "$BUILT_PRODUCTS_DIR/$CONTENTS_FOLDER_PATH/Resources/HTML" HTML/*.coffee
coffee -o "$DESTINATION_SCRIPTS_DIR/HTML/" HTML/*.coffee
cp -r "$SOURCE_SCRIPTS_DIR" "$DESTINATION_SCRIPTS_DIR"