Mailing Lists: Apple Mailing Lists
Image of Mac OS face in stamp
Re: Launch Services and CFBundleVersion
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Launch Services and CFBundleVersion



Ack, at 6/7/06, Christopher Linn said:

The documentation has an important caveat which should be noted:

This string is usually of the form

The operative word in this case being "usually." It's difficult to code to this spec.

I noticed that too and then saw:

The second and third numbers are minor revision numbers and must be a single numeric digit.

right after it, the operative word in this case being "must".


I can tell you that when comparing version numbers for document binding purposes, Launch Services respects the first three version components, but IGNORES the development stage code (a, b, d, etc.) and anything following it.

That is odd to me since I usually release public betas of junk and stuff.

It's true that many instances of CFBundleVersion values do not conform to the requirements of CFBundleGetVersionNumber(). Internally, Launch Services is more flexible in recognition of Info.plist reality. Effectively, LS expects the following format: nnnnn[.nn[.nn]][X] where n is a digit 0-9, square brackets indicate optional components, and X is any string not starting with a digit. X is ignored when present.

It actually makes sense that LS is smarter than CF. Sadly, the LS method will still fail for windows style version numbers such as 5.1.2600.1519 (yes, that's a joke).
--



Sincerely, Rosyna Keller Technical Support/Holy Knight/Always needs a hug

Unsanity: Unsane Tools for Insanely Great People

It's either this, or imagining Phil Schiller in a thong.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Carbon-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Launch Services and CFBundleVersion (From: Dave Dribin <email@hidden>)
 >Re: Launch Services and CFBundleVersion (From: Christopher Linn <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2011 Apple Inc. All rights reserved.