How to restrict Deploy updates by native version

Overview:

Native Versioning allows you to control when an update should happen based on native features and binary version.

For instance, if you have Deploy pulling from the "Production" Channel, and you push an update that requires a native plugin that didn't exist until version 1.2.3 of your App, you'll want to set the iOS/Android Minimum version to 1.2.3. This will prevent earlier versions of your App from downloading live updates that require that native functionality. See the following articles for more details on Deploy and binary compatible live updates.

Procedure:

Open a commit by clicking into your app > Deploy > Builds > and select your Deploy build from the list

Navigate to the Versioning tab > enter the appropriate version for each platform > click Save. The native versions for a commit must be defined for each platform.

Fields are defined as follows:

Minimum: Native binary must be at least this version in order to download this update through Deploy.

Maximum: Native binary must be this version or below in order to download this update through Deploy.

Equivalent: If the Native binary is this version, do NOT download this update through Deploy, because they are equal.

In the example shown above:

Users running version 1.0.0 will not receive the update because the version is lower than the minimum version requirement.

Users running version 1.0.1 will receive the update because the version meets the minimum version requirement.

Users running version 1.0.2 will not receive the update because the version matches the equivalent version.

Users running version 1.0.3 to 2.0.0 will receive the update because the version meets the maximum version requirement.

Users running version 2.0.1+ will not receive the update because the version is greater than the maximum version requirement.

Example Scenario:

Below is an example of a common native versioning scheme. In this scenario we'll be managing each native release (distributed through the App Store/Play Store) with equivalent, and minimum version requirements. Bear in mind that all changes to an app's native configuration will require a new native build, and distribution via an app store. See our doc on binary compatible changes for more details on when a new native build is necessary.

We'll manage updates to our webcode using the minimum version exclusively. This will allow for seamless updates for a given native version.

Commit Version

Min

Max

Equivalent

1.0.0 (native)

1.0.0

1.0.0

1.0.1

1.0.0

1.0.2

1.0.0

1.1.0 (native)

1.1.0

1.1.0

1.1.1

1.1.0

1.1.2

1.1.0

2.0.0 (native)

2.0.0

2.0.0

2.0.1

2.0.0

Ionic recommends disabling auto-assignment from git branches on production channels. Deploys to production channels should be handled manually via the dashboard. As a best practice we recommend that only commits intended for release be deployed to a channel.