Codemagic versioning for iOS of Flutter
This seems to be a Flutter build command that you are using and specific to flutter build command rather than CI/CD service provider.
If you are settings build version and name from build arguments then the build command determines the outcome. see: https://flutter.dev/docs/deployment/ios#updating-the-apps-version-number
specifically from docs:
In iOS, build-name uses CFBundleShortVersionString while build-number uses CFBundleVersion. Read more about iOS versioning at Core Foundation Keys on the Apple Developer’s site.
Comments
-
Andrew Piterov over 1 year
I've faced the next issue with Codemagic: at the beginning in Info.plist were ${CURRENT_PROJECT_VERSION} for Bundle Version and ${MARKETING_VERSION} for Bundle Version string (short) and these lines above did not work
The place to put these lines in Codemagic
--build-name=2.0.$BUILD_NUMBER --build-number=$BUILD_NUMBER --build-name=2.0.$PROJECT_BUILD_NUMBER --build-number=$PROJECT_BUILD_NUMBER
But after I changed to ${FLUTTER_BUILD_NUMBER} and ${FLUTTER_BUILD_NAME} for Bundle Version and Bundle Version string (short) respectively lines above in Codemagic started to do magic, they start to work.
Could someone explain why at the beginning with ${CURRENT_PROJECT_VERSION} and ${MARKETING_VERSION} Codemagic could not set the version that I wrote? Thanks.