cordova-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ste...@apache.org
Subject [14/51] [abbrv] git commit: Update Identity.Name in package.appxmanifest
Date Wed, 27 Nov 2013 22:27:13 GMT
Update Identity.Name in package.appxmanifest


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

Branch: refs/heads/fireos
Commit: 1da2a964ed87df1b2185e75d681778ad6499d990
Parents: f6d4c75
Author: SomaticIT <contact@somatic.fr>
Authored: Fri Nov 15 16:34:21 2013 +0100
Committer: SomaticIT <contact@somatic.fr>
Committed: Fri Nov 15 16:34:21 2013 +0100

----------------------------------------------------------------------
 src/metadata/windows8_parser.js | 15 +++++++++++----
 1 file changed, 11 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-cli/blob/1da2a964/src/metadata/windows8_parser.js
----------------------------------------------------------------------
diff --git a/src/metadata/windows8_parser.js b/src/metadata/windows8_parser.js
index 4e331b5..d0bf4ed 100644
--- a/src/metadata/windows8_parser.js
+++ b/src/metadata/windows8_parser.js
@@ -79,19 +79,26 @@ module.exports.prototype = {
         //Get manifest file
         var manifest = xml.parseElementtreeSync(this.manifest_path);
 
-        //Update app version
         var version = this.fixConfigVersion(config);
+        var name = config.name();
+        var pkgName = config.packageName();
+
         var identityNode = manifest.find('.//Identity');
         if(identityNode) {
+            // Update app name in identity
+            var appIdName = identityNode['attrib']['Name'];
+            if (appIdName != pkgName) {
+                identityNode['attrib']['Name'] = pkgName;
+            }
+
+            // Update app version
             var appVersion = identityNode['attrib']['Version'];
             if(appVersion != version) {
                 identityNode['attrib']['Version'] = version;
             }
         }
 
-        // update name ( windows8 has it in the Application[@Id] and Application.VisualElements[@DisplayName])
-        var pkgName = config.packageName();
-        var name = config.name();
+        // Update name (windows8 has it in the Application[@Id] and Application.VisualElements[@DisplayName])
         var app = manifest.find('.//Application');
         if(app) {
 


Mime
View raw message