app

AppInfo

Application information delivered in nice Swifty way

Showing:

Popularity

Downloads/wk

0

GitHub Stars

37

Maintenance

Last Commit

7yrs ago

Contributors

2

Package

Dependencies

0

License

MIT

Categories

Readme

AppInfo

Get information about your app in Swifty way

The Idea

Do you remember yourself doing this? Can remember all the keys? How many times have you searched for the right names?

let text = NSBundle.mainBundle().infoDictionary?["CFBundleVersion"]

// Keys
"CFBundleDisplayName", "CFBundleVersion", "UIRequiredDeviceCapabilities", "UIMainStoryboardFile", ...

Wouldn't it be awesome to have Xcode to show them all? And be staticly typed!?

Enter AppInfo.

Usage

AppInfo provides an static typed API for working with infoDictionary.

let name = AppInfo.CFBundleName 
let build = AppInfo.CFBundleVersion
let version = AppInfo.CFBundleShortVersionString
let devices = AppInfo.UIDeviceFamily

/*
Results:
Name - "DemeApp", String
build - 2, Int
version - "1.0", String
devices - ["armv7"], Array
/*

Benefits

  • Static typed keys. No string keys anymore
  • Static typed values. Correct key values: Int, String, Array ...

Installation

Copied files

The simplest way - copy AppInfo/Classes/AppInfo.swift to your project. That's it!

CocoaPods

use_frameworks!
pod 'AppInfo'

Then import it to your project:

import AppInfo

Note: This requires CocoaPods 0.36 as well as iOS 8

Contribute

Please open an issue with bugs and missing features, functionality or ideas for improvements.

Also you can contribute by following this guidelines:

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create pull request

Author

Kostiantyn Koval, @KostiaKoval

License

AppInfo is available under the MIT license. See the LICENSE file for more info.

Rate & Review

Great Documentation0
Easy to Use0
Performant0
Highly Customizable0
Bleeding Edge0
Responsive Maintainers0
Poor Documentation0
Hard to Use0
Slow0
Buggy0
Abandoned0
Unwelcoming Community0
100