How can I read a plist file that is within the contents of an application? (OS X)

Comments

1 comment

  • Avatar
    jesus

    The Info.plist files are XML files so you can simply use the <xmlfileget> and <xmlfileset> to manipulate the values.

    For instance:

    <xmlFileGet>
        <attribute></attribute>
        <element>/plist/dict[1]/string[preceding-sibling::key[1]/text()="CFBundleVersion"]</element>
        <file>${installdir}/some.app/Contents/Info.plist</file>
        <variable>version</variable>
    </xmlFileGet>
    

Please sign in to leave a comment.