• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Question about Info.plist's
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Question about Info.plist's


  • Subject: Re: Question about Info.plist's
  • From: "Glenn L. Austin via Cocoa-dev" <email@hidden>
  • Date: Wed, 19 Aug 2020 09:44:45 -0700

No, you can't use an "earlier" key to create a "later" value - but you can use
code to do basically the same thing.

Or, you can use the same variable that sets your CFBuildNumber to set your
CFBundleVersion.

--
Glenn L. Austin, Computer Wizard and Race Car Driver         <><
<http://www.austinsoft.com>

> On Aug 19, 2020, at 9:07 AM, Gabriel Zachmann via Cocoa-dev
> <email@hidden> wrote:
>
> Question:
>
> Is there a way to use a key/value that was defined earlier in the plist file
> to define a value for a later key?
>
> Explanation:
> I have a macOS project with an automatically created "About" window.
> The plist file has, additionally to all the default stuff, the key
> CFBuildNumber (with a value that I increment automatically).
>
> In Xcode, I tried to change "Bundle version" to a value like
>
>   $(CURRENT_PROJECT_VERSION)_$(CFBuildNumber)
>
> However, in the final Info.plist in the app's bundle, this then looks like
>
>    <key>CFBundleVersion</key>
>    <string>3.1_</string>
>
> Notice the underscore, but the value of CFBuildNumber is gone.
> "3.1", BTW, is the value I have set under
>
>    Project / Targets / General / Identity / Build
>
> I have tried to change parentheses into curly braces, to no avail.
>
> So, question again: is there a way to use a key/value that was defined
> earlier in the plist file
> to define a value for a later key?
> I'd like to do that so that the "About" window contains the build number, too.
>
> Thanks a lot in advance.
>
>
> _______________________________________________
>
> Cocoa-dev mailing list (email@hidden)
>
> Please do not post admin requests or moderator comments to the list.
> Contact the moderators at cocoa-dev-admins(at)lists.apple.com
>
> Help/Unsubscribe/Update your Subscription:
>
> This email sent to email@hidden

Attachment: signature.asc
Description: Message signed with OpenPGP

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Question about Info.plist's
      • From: Gabriel Zachmann via Cocoa-dev <email@hidden>
    • Re: Question about Info.plist's
      • From: Owen Hartnett via Cocoa-dev <email@hidden>
References: 
 >Question about Info.plist's (From: Gabriel Zachmann via Cocoa-dev <email@hidden>)

  • Prev by Date: Question about Info.plist's
  • Next by Date: Re: AddInstanceForFactory: No factory registered for id
  • Previous by thread: Question about Info.plist's
  • Next by thread: Re: Question about Info.plist's
  • Index(es):
    • Date
    • Thread