CFBundleGetInfoString & Snow Leopard
CFBundleGetInfoString & Snow Leopard
- Subject: CFBundleGetInfoString & Snow Leopard
- From: Eric Gorr <email@hidden>
- Date: Wed, 23 Sep 2009 13:36:55 -0400
With Snow Leopard, the CFBundleGetInfoString string is now obsolete.
The string assigned to this key will show up in the Version field in
the Get Info window if NSHumanReadableCopyright is not defined.
For my application, I set CFBundleGetInfoString to:
Major.Minor.Bug (Build #), Copyright 2010 My Company, Inc.
So, it might look like on the Get Info window:
15.1.2 (324569), Copyright 2010 My Company, Inc.
I would like to adopt the recommended method and start defining
NSHumanReadableCopyright. Once this key is defined, Snow Leopard will
ignore CFBundleGetInfoString.
But, with the NSHumanReadableCopyright key defined, what appears in
the Version field of the Get Info window is the string defined for
CFBundleShortVersionString.
The documentation for CFBundleShortVersionString says:
CFBundleShortVersionString (String) specifies the release
version number of the bundle, which identifies a released
iteration of the application. The release version number
is a string comprised of three period-separated integers.
The first integer represents major revisions to the
application, such as revisions that implement new features
or major changes. The second integer denotes revisions that
implement less prominent features. The third integer
represents maintenance releases.
The value for this key differs from the value
for “CFBundleVersion,” which identifies an iteration
(released or unreleased) of the application.
So, it would appear that including my Build # in
CFBundleShortVersionString is inappropriate - i.e. it should be:
15.1.2
and not
15.1.2 (324569)
If I placed "(324569)" in the CFBundleShortVersionString would it
cause problems?
Now, the problem is that it is useful on occasion to be able to easily
determine what the Build # of the application is without launching the
application and going to an About Box - perhaps because the
application doesn't launch for some reason.
If my understanding of the keys is correct, there is no longer a good
place for me to place the Build # and have it appear in the Get Info
dialog. I suppose it could be placed in the NSHumanReadableCopyright
string, but this isn't particularly satisfying. If I am guaranteed
that placing it in CFBundleShortVersionString won't cause problems,
I'd just leave it there, but the documentation seems to indicate this
is definitely the wrong thing to do...the Build # should be placed in
CFBundleVersion.
Any thoughts or comments on this?
p.s. documentation on these key can be found at:
http://developer.apple.com/mac/library/documentation/MacOSX/Conceptual/BPRuntimeConfig/Articles/PListKeys.html#//apple_ref/doc/uid/20001431-BCIJIJBH
_______________________________________________
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