Method: RunLoop::App#marketing_version
- Defined in:
- lib/run_loop/app.rb
#marketing_version ⇒ RunLoop::Version? Also known as: short_bundle_version
Returns the CFBundleShortVersionString of the app as Version instance.
Apple docs:
CFBundleShortVersionString specifies the release version number of the bundle, which identifies a released iteration of the app. The release version number is a string comprised of three period-separated integers.
The first integer represents major revisions to the app, 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 app. This key can be localized by including it in your InfoPlist.strings files.
165 166 167 168 169 170 171 172 173 174 175 176 177 178 |
# File 'lib/run_loop/app.rb', line 165 def marketing_version string = plist_buddy.plist_read("CFBundleShortVersionString", info_plist_path) begin version = RunLoop::Version.new(string) rescue if string && string != "" RunLoop.log_debug("CFBundleShortVersionString: '#{string}' is not a well formed version string") else RunLoop.log_debug("CFBundleShortVersionString is not defined in Info.plist") end version = nil end version end |