You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by pu...@apache.org on 2014/12/05 20:17:07 UTC

[1/2] cordova-windows git commit: Fixed regex used in getPackageFileInfo().

Repository: cordova-windows
Updated Branches:
  refs/heads/master dd514e02e -> f5bb455d8


Fixed regex used in getPackageFileInfo().

Match failed for version that contains more than one digit in any part (e.g. 1.1.1.99).

Project: http://git-wip-us.apache.org/repos/asf/cordova-windows/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-windows/commit/8082c33e
Tree: http://git-wip-us.apache.org/repos/asf/cordova-windows/tree/8082c33e
Diff: http://git-wip-us.apache.org/repos/asf/cordova-windows/diff/8082c33e

Branch: refs/heads/master
Commit: 8082c33eef77a0fa5d88e1ae9b43c9fa347a94bc
Parents: dd514e0
Author: Michael Dudek <mi...@centrum.cz>
Authored: Tue Nov 25 15:29:54 2014 +0100
Committer: Michael Dudek <mi...@centrum.cz>
Committed: Tue Nov 25 15:29:54 2014 +0100

----------------------------------------------------------------------
 template/cordova/lib/package.js | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/8082c33e/template/cordova/lib/package.js
----------------------------------------------------------------------
diff --git a/template/cordova/lib/package.js b/template/cordova/lib/package.js
index 20c0e2a..6835fe0 100644
--- a/template/cordova/lib/package.js
+++ b/template/cordova/lib/package.js
@@ -67,7 +67,7 @@ module.exports.getPackageFileInfo = function (packageFile) {
     var pkgName = path.basename(packageFile);
     // CordovaApp.Windows_0.0.1.0_anycpu_debug.appx
     // CordovaApp.Phone_0.0.1.0_x86_debug.appxbundle
-    var props = /.*\.(Phone|Windows|Windows80)_((?:\d\.)*\d)_(AnyCPU|x64|x86|ARM)(?:_(Debug))?.(appx|appxbundle)$/i.exec(pkgName);
+    var props = /.*\.(Phone|Windows|Windows80)_((?:\d\.)*\d*)_(AnyCPU|x64|x86|ARM)(?:_(Debug))?.(appx|appxbundle)$/i.exec(pkgName);
     if (props) {
         return {type      : props[1].toLowerCase(),
             arch      : props[3].toLowerCase(),
@@ -175,4 +175,4 @@ module.exports.deployToDesktop = function (appxScript, deployTarget) {
             });
         });
     });
-};
\ No newline at end of file
+};


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org


[2/2] cordova-windows git commit: Fixed regex used in getPackageFileInfo().

Posted by pu...@apache.org.
Fixed regex used in getPackageFileInfo().

The previous regex update fixed only versions with multiple digits in last part of version number.

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

Branch: refs/heads/master
Commit: f5bb455d84197f1cc3eb04ab50eba915167746ac
Parents: 8082c33
Author: Michael Dudek <mi...@centrum.cz>
Authored: Tue Nov 25 15:47:55 2014 +0100
Committer: Michael Dudek <mi...@centrum.cz>
Committed: Tue Nov 25 15:47:55 2014 +0100

----------------------------------------------------------------------
 template/cordova/lib/package.js | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-windows/blob/f5bb455d/template/cordova/lib/package.js
----------------------------------------------------------------------
diff --git a/template/cordova/lib/package.js b/template/cordova/lib/package.js
index 6835fe0..561e5c4 100644
--- a/template/cordova/lib/package.js
+++ b/template/cordova/lib/package.js
@@ -67,7 +67,7 @@ module.exports.getPackageFileInfo = function (packageFile) {
     var pkgName = path.basename(packageFile);
     // CordovaApp.Windows_0.0.1.0_anycpu_debug.appx
     // CordovaApp.Phone_0.0.1.0_x86_debug.appxbundle
-    var props = /.*\.(Phone|Windows|Windows80)_((?:\d\.)*\d*)_(AnyCPU|x64|x86|ARM)(?:_(Debug))?.(appx|appxbundle)$/i.exec(pkgName);
+    var props = /.*\.(Phone|Windows|Windows80)_((?:\d*\.)*\d*)_(AnyCPU|x64|x86|ARM)(?:_(Debug))?.(appx|appxbundle)$/i.exec(pkgName);
     if (props) {
         return {type      : props[1].toLowerCase(),
             arch      : props[3].toLowerCase(),


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org