Flutter_say_what
Flutter_say_what

Reputation: 93

Can my Flutter project have a different version number for Android and iOS?

Is it possible to use pubspec and the flutter build tools to create release versions of my app with a different version for each platform? Eg iOS could be 1.0.1+10 and Android 5.2.3?

This is wrong but I'm thinking something like like the below

name: myapp
description: my app description
ios_version: 1.0.1+10
android_version: 5.2.3

Currently the apps in the stores have different version numbers. Would we need to bump them both to the same version, say 6.0.0? Is it possible to have a pubspec for each version?

Upvotes: 6

Views: 2354

Answers (2)

For Andriod edit the local.properties file inside android folder when you are building.

For iOS edit the Generated.xcconfig file inside ios/FLutter folder or update from Xcode when you are building.

FLUTTER_BUILD_NAME=1.0.0

FLUTTER_BUILD_NUMBER=1

Upvotes: 1

Dharmesh Mansata
Dharmesh Mansata

Reputation: 4738

For iOS find the file name Generated.xcconfig and change the following parameter

FLUTTER_BUILD_NAME=1.0.0

FLUTTER_BUILD_NUMBER=1

Otherwise, default version getting from pubspec.yaml from the following line :

version: 1.0.0+1 // default version set

Upvotes: 2

Related Questions