You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by dr...@apache.org on 2013/10/15 20:40:05 UTC

[24/31] git commit: ios release/master compatibility

ios release/master compatibility


Project: http://git-wip-us.apache.org/repos/asf/cordova-medic/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-medic/commit/9fdc6eee
Tree: http://git-wip-us.apache.org/repos/asf/cordova-medic/tree/9fdc6eee
Diff: http://git-wip-us.apache.org/repos/asf/cordova-medic/diff/9fdc6eee

Branch: refs/heads/master
Commit: 9fdc6eee582cb5905e40807145cffc4f6629cc3f
Parents: c96d383
Author: David Kemp <dr...@google.com>
Authored: Wed Aug 28 09:51:51 2013 -0400
Committer: David Kemp <dr...@chromium.org>
Committed: Tue Oct 15 14:13:54 2013 -0400

----------------------------------------------------------------------
 master.cfg              | 3 +++
 src/build/makers/ios.js | 4 ++--
 2 files changed, 5 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-medic/blob/9fdc6eee/master.cfg
----------------------------------------------------------------------
diff --git a/master.cfg b/master.cfg
index 8653e4d..7b394f8 100644
--- a/master.cfg
+++ b/master.cfg
@@ -156,6 +156,7 @@ if(build_ios) :
     factory_IOS.addStep(ShellCommand(command=["/bin/sh","-c","./cordova-coho/coho repo-clone -r plugins -r mobile-spec -r ios -r cli -r js "],workdir='build',haltOnFailure=True,description='COHO Clone', descriptionDone='COHO Clone'))
     factory_IOS.addStep(ShellCommand(command=["node","medic/checkout.js","--path=../../../repos.json","--cat=PLUGIN","--releasebranch="+branch_release,"--release"],workdir='build',haltOnFailure=False,description='Plugins->master',descriptionDone='Plugins->master'))
     factory_IOS.addStep(ShellCommand(command=["node","medic/checkout.js","--path=../../../repos.json","--cat=PLATFORM","--releasebranch="+branch_release,"--release"],workdir='build',haltOnFailure=False,description='Platform->release',descriptionDone='Platform->release'))
+    factory_IOS.addStep(ShellCommand(command=["node","medic/checkout.js","--path=../../../repos.json","--cat=MSPEC","--releasebranch="+branch_release,"--release"],workdir='build',haltOnFailure=False,description='Mspec->release',descriptionDone='Mspec->release'))
     factory_IOS.addSteps(common_steps_mobilespec_1)
     factory_IOS.addStep(ShellCommand(command=["node","medic/writejson.js","--branch="+branch_release],workdir='build',haltOnFailure=True, description='Write json',descriptionDone='Write json'))
     factory_IOS.addStep(ShellCommand(command=["../cordova-cli/bin/cordova","platform","add","ios"],workdir='build/mobilespec',haltOnFailure=True,description='Platform Add',descriptionDone='Platform Add'))
@@ -170,6 +171,7 @@ if(build_android) :
     factory_Android.addStep(ShellCommand(command=["/bin/sh","-c","./cordova-coho/coho repo-clone -r plugins -r mobile-spec -r android -r cli -r js "],workdir='build',haltOnFailure=True,description='COHO Clone', descriptionDone='COHO Clone'))
     factory_Android.addStep(ShellCommand(command=["node","medic/checkout.js","--path=../../../repos.json","--cat=PLUGIN","--releasebranch="+branch_release,"--release"],workdir='build',haltOnFailure=False,description='Plugins->master',descriptionDone='Plugins->master'))
     factory_Android.addStep(ShellCommand(command=["node","medic/checkout.js","--path=../../../repos.json","--cat=PLATFORM","--releasebranch="+branch_release,"--release"],workdir='build',haltOnFailure=False,description='Platform->release',descriptionDone='Platform->release'))
+    factory_Android.addStep(ShellCommand(command=["node","medic/checkout.js","--path=../../../repos.json","--cat=MSPEC","--releasebranch="+branch_release,"--release"],workdir='build',haltOnFailure=False,description='Mspec->release',descriptionDone='Mspec->release'))
     factory_Android.addSteps(common_steps_mobilespec_1)
     factory_Android.addStep(ShellCommand(command=["node","medic/writejson.js","--branch="+branch_release],workdir='build',haltOnFailure=True, description='Write json',descriptionDone='Write json'))
     factory_Android.addStep(ShellCommand(command=["../cordova-cli/bin/cordova","platform","add","android"],workdir='build/mobilespec',haltOnFailure=True,description='Platform Add',descriptionDone='Platform Add'))
@@ -200,6 +202,7 @@ if(build_android) :
     factory_Android_master.addStep(ShellCommand(command=["/bin/sh","-c","./cordova-coho/coho repo-clone -r plugins -r mobile-spec -r android -r cli -r js "],workdir='build',haltOnFailure=True,description='COHO Clone', descriptionDone='COHO Clone'))
     factory_Android_master.addStep(ShellCommand(command=["node","medic/checkout.js","--path=../../../repos.json","--cat=PLUGIN","--releasebranch="+branch_release],workdir='build',haltOnFailure=False,description='Plugins->dev',descriptionDone='Plugins->dev'))
     factory_Android_master.addStep(ShellCommand(command=["node","medic/checkout.js","--path=../../../repos.json","--cat=PLATFORM","--releasebranch="+branch_release],workdir='build',haltOnFailure=False,description='Platform->master',descriptionDone='Platform->master'))
+    factory_Android_master.addStep(ShellCommand(command=["/bin/sh","-c",'[ -f "package.json" ] && npm install'],workdir='build/cordova-android/bin',haltOnFailure=True,description='NPM Install', descriptionDone='NPM Install'))
     factory_Android_master.addSteps(common_steps_mobilespec_1)
     factory_Android_master.addStep(ShellCommand(command=["node","medic/writejson.js","--branch=master"],workdir='build',haltOnFailure=True, description='Write json',descriptionDone='Write json'))
     factory_Android_master.addStep(ShellCommand(command=["../cordova-cli/bin/cordova","platform","add","android"],workdir='build/mobilespec',haltOnFailure=True, description='Platform Add',descriptionDone='Platform Add'))

http://git-wip-us.apache.org/repos/asf/cordova-medic/blob/9fdc6eee/src/build/makers/ios.js
----------------------------------------------------------------------
diff --git a/src/build/makers/ios.js b/src/build/makers/ios.js
index 148c5cc..98ab500 100644
--- a/src/build/makers/ios.js
+++ b/src/build/makers/ios.js
@@ -55,7 +55,7 @@ module.exports = function(output,lib_location,test_dir, sha, devices, entry_poin
                         // TODO: expose which target sdk to build for
                         var debugScript = path.join(output, 'cordova', 'build');
                         // note that the following has to work for 3.0.0 and later and it change just AFTER 3.0.x release
-                        fs.writeFileSync(debugScript, fs.readFileSync(debugScript, 'utf-8').replace(/configuration Debug/, 'configuration Release').replace(/i386/g,'armv7').replace(/iphonesimulator/, 'iphoneos').replace(/SDK=`.*`/, 'SDK="iphoneos"'), 'utf-8');
+                        fs.writeFileSync(debugScript, fs.readFileSync(debugScript, 'utf-8').replace(/"$PROJECT_PATH\/build"/, '"$PROJECT_PATH/build/device"').replace(/i386/g,'armv7').replace(/iphonesimulator/, 'iphoneos').replace(/SDK=`.*`/, 'SDK="iphoneos"'), 'utf-8');
                     } catch(e) {
                         error_writer('ios', sha, 'Exception thrown modifying mobile spec application for iOS.', e.message);
                         callback(true);
@@ -64,7 +64,7 @@ module.exports = function(output,lib_location,test_dir, sha, devices, entry_poin
                     // compile
                     log('Compiling.');
                         
-                    var debug = 'cd ' + output + ' && ./cordova/build';
+                    var debug = 'cd ' + output + ' && ./cordova/build --release';
                     var compile = shell.exec(debug, {silent:true});
                     if (compile.code > 0) {
                             error_writer('ios', sha, 'Compilation error.', compile.output);