Uploaded image for project: 'Apache Cordova'
  1. Apache Cordova
  2. CB-6472

Adding content to -Info.plist - Unexpected behaviour

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 3.4.0
    • None
    • cordova-plugman
    • None
    • Mac OS X

    Description

      Trying to add content NOT at the root of info.plist, to a node already having existing content.

      The existing content gets deleted, not merged with new content.

      Use case: a plugin providing Newsstand integration.

      Doing this in plugin.xml:

              <config-file target="*-Info.plist" parent="CFBundleIcons">
                  <dict>
                      <key>CFBundlePrimaryIcon</key>
                      <dict>
                          <key>UINewsstandIcon</key>
                          <dict>
                             ...
      

      Info.plist before install:

          <key>CFBundleIcons</key>
          <dict>
            <key>CFBundlePrimaryIcon</key>
            <dict>
              <key>CFBundleIconFiles</key>
              <array>
                ...
              </array>
            </dict>
          </dict>
      

      Info.plist after install:

          <key>CFBundleIcons</key>
          <dict>
            <key>CFBundlePrimaryIcon</key>
            <dict>
              <key>UINewsstandIcon</key>
              <dict>
                ...
              </dict>
            </dict>
          </dict>
      

      Info.plist expected:

          <key>CFBundleIcons</key>
          <dict>
            <key>CFBundlePrimaryIcon</key>
            <dict>
              <key>UINewsstandIcon</key>
              <dict>
                ...
              </dict>
              <key>CFBundleIconFiles</key>
              <array>
                ...
              </array>
            </dict>
          </dict>
      

      If this is not unexpected behaviour, then I'd make this issue a feature request: adding an option like "merge=true".

      Attachments

        Activity

          People

            Unassigned Unassigned
            jchoelt Jean-Christophe Hoelt
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: