cordova-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From agri...@apache.org
Subject [4/4] git commit: Fix zippush causing files to be base64 encoded (typo in prev commit)
Date Thu, 19 Jun 2014 01:45:09 GMT
Fix zippush causing files to be base64 encoded (typo in prev commit)


Project: http://git-wip-us.apache.org/repos/asf/cordova-app-harness/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-app-harness/commit/5047e0ea
Tree: http://git-wip-us.apache.org/repos/asf/cordova-app-harness/tree/5047e0ea
Diff: http://git-wip-us.apache.org/repos/asf/cordova-app-harness/diff/5047e0ea

Branch: refs/heads/master
Commit: 5047e0ead2fb048953c203e87f35981108b9e99d
Parents: c8fdd7c
Author: Andrew Grieve <agrieve@chromium.org>
Authored: Wed Jun 18 21:44:36 2014 -0400
Committer: Andrew Grieve <agrieve@chromium.org>
Committed: Wed Jun 18 21:44:56 2014 -0400

----------------------------------------------------------------------
 harness-push/node_modules/cordova-harness-client/pushsession.js | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-app-harness/blob/5047e0ea/harness-push/node_modules/cordova-harness-client/pushsession.js
----------------------------------------------------------------------
diff --git a/harness-push/node_modules/cordova-harness-client/pushsession.js b/harness-push/node_modules/cordova-harness-client/pushsession.js
index 1b0e9c0..d878198 100644
--- a/harness-push/node_modules/cordova-harness-client/pushsession.js
+++ b/harness-push/node_modules/cordova-harness-client/pushsession.js
@@ -174,7 +174,9 @@ function zipDir(dir, zip) {
                 var inner = zip.folder(f);
                 zipDir(path.join(dir, f), inner);
             } else {
-                zip.file(f, fs.readFileSync(fullPath, 'base64'), { binary: true, optimizedBinaryString:
true });
+                // 'binary' actually means binary string.
+                // Using optimizedBinaryString speeds things up *a lot*.
+                zip.file(f, fs.readFileSync(fullPath, 'binary'), { binary: true, optimizedBinaryString:
true });
             }
         }
     });


Mime
View raw message