SSAppUpdater is an open-source framework that compares the current version of the app with the store version and returns the essential details of it like app URL, new app version number, new release note, etc. So you can either redirect or notify the user to update their app.
Force Update | Optional Update | Skip Version |
---|---|---|
Force update | Optional update |
---|---|
Skip version | Update with custom alert |
---|---|
- Check for new version of your installed application
- Provides new version release note
- Provides AppID and AppStore URL
- Provides support of custom alerts for updates.
- CocoaPods
- iOS 13.0+
- macOS 11.0+
- Xcode 9+
-
You can use CocoaPods to install SSAppUpdater by adding it to your Podfile:
use_frameworks! pod 'SSAppUpdater'
-
import SSAppUpdater
- Download and drop SSAppUpdater folder in your project.
- Congratulations!
- When using Xcode 11 or later, you can install
SSAppUpdater
by going to your Project settings >Swift Packages
and add the repository by providing the GitHub URL. Alternatively, you can go toFile
>Swift Packages
>Add Package Dependencies...
dependencies: [
.package(url: "https://github.com/SimformSolutionsPvtLtd/SSAppUpdater.git", from: "1.1.0")
]
- Carthage is a decentralized dependency manager that builds your dependencies and provides you with binary frameworks.You can install Carthage with Homebrew using the following command:
$ brew update
$ brew install carthage
To integrate SSAppUpdater
into your Xcode project using Carthage, add the following line to your Cartfile
:
github ""SimformSolutionsPvtLtd/SSAppUpdater""
Run carthage
to build and drag the SSAppUpdater
(Sources/SSAppUpdater) into your Xcode project.
-
SSAppUpdater compares the currently installed version of your iOS app with the new store version that is currently available in the App Store. When an update is available, SSAppUpdater is able to present the new version number, Appstore URL, App ID, and release notes to the user giving them the choice to update.
-
How does SSAppUpdater achieve this? Firstly, it makes use of the iTunes Search API to retrieve the information.
-
Parameters usage:
isForceUpdate
- Boolean value checks that the user wants to force update or not.updateAlertFrequency
- The user can choose alert display time. default value will be.always
. Alternative values of this property aredaily
,weekly
andmonthly
.showDefaultAlert
- Developers using SSAppUpdater can customize the user interface as required. The Boolean value "showDefaultAlert" determines whether to display the default alert or a custom UI, based on the user's preference.skipVersionAllow
- This feature lets users activate the "skipVersion" functionality.redirectToMacAppStore
- This setting is specifically for macOS users. It gives them the choice to either be directed to the App Store app or stay within the current application to access the App Store.
-
Implementing SSAppUpdater quite easy just add below provided code in your
AppDelegate.swift
or anywhere in your app you need. -
The block will provide version information which can then be utilized to generate an custom alert.
//defaultExample
SSAppUpdater.shared.performCheck { (versionInfo) in
// Version Info have all the app update related information
// Display AppUpdate UI based on versionInfo.isAppUpdateAvailable flag
}
//customExample
SSAppUpdater.shared.performCheck(isForceUpdate: false, updateAlertFrequency: .always, showDefaultAlert: false) { (versionInfo) in
// Version Info have all the app update related information
}
- SSAppUpdater inspired from Siren