cordova-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From agri...@apache.org
Subject [3/3] git commit: Make repo-update update dev branched by default.
Date Mon, 16 Sep 2013 18:18:46 GMT
Make repo-update update dev branched by default.

And make repo-clone checkout dev branches for plugins.


Project: http://git-wip-us.apache.org/repos/asf/cordova-coho/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-coho/commit/5e21d439
Tree: http://git-wip-us.apache.org/repos/asf/cordova-coho/tree/5e21d439
Diff: http://git-wip-us.apache.org/repos/asf/cordova-coho/diff/5e21d439

Branch: refs/heads/master
Commit: 5e21d4394752ba13e144b8a23fe0e060f8bcc648
Parents: e5ba6cb
Author: Andrew Grieve <agrieve@chromium.org>
Authored: Mon Sep 16 14:18:11 2013 -0400
Committer: Andrew Grieve <agrieve@chromium.org>
Committed: Mon Sep 16 14:18:11 2013 -0400

----------------------------------------------------------------------
 coho | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-coho/blob/5e21d439/coho
----------------------------------------------------------------------
diff --git a/coho b/coho
index 015fa92..bf85228 100755
--- a/coho
+++ b/coho
@@ -718,6 +718,13 @@ function repoCloneCommand(argv) {
     process.exit(0);
 }
 
+function checkoutDevBranch(repos) {
+    forEachRepo(repos, function(repo) {
+        var branchName = pluginRepos.indexOf(repo) == -1 ? 'master' : 'dev';
+        gitCheckout(branchName);
+    });
+}
+
 function cloneRepos(repos, quiet) {
     var failures = [];
     var numSkipped = 0;
@@ -730,6 +737,8 @@ function cloneRepos(repos, quiet) {
             var code = shjs.exec('git clone --progress ' + createRepoUrl(repo)).code;
             if (code) {
                 failures.push(repo.repoName);
+            } else {
+                checkoutDevBranch([repo]);
             }
         }
     });
@@ -950,7 +959,7 @@ function repoUpdateCommand(argv) {
         .options('b', {
             alias: 'branch',
             desc: 'The name of the branch to update. Can be specified multiple times to update
multiple branches.',
-            default: 'master'
+            default: ['master', 'dev']
          })
         .options('fetch', {
             type: 'boolean',


Mime
View raw message