Skip to content

BUILD_NUMBER is used for both build number and minor version #158

@JavascriptMick

Description

@JavascriptMick

Describe the sample projects update you'd like to see
In the sample yaml for flutter (flutter/flutter-android-and-ios-yaml-demo-project/codemagic.yaml) , the BUILD_NUMBER is correctly retrieved from google play but is then incorrectly used as both the minor version of the app version number and the build number.

BUILD_NUMBER=$(($(google-play get-latest-build-number --package-name "$PACKAGE_NAME" --tracks="$GOOGLE_PLAY_TRACK") + 1))      
          flutter build appbundle --release \
            --build-name=1.0.$BUILD_NUMBER \
            --build-number=$BUILD_NUMBER

I think it would be more correct if the BUILD_NUMBER variable were only used for the --build-number setting. the build-name is meant to change less frequently and could either be hard coded by the user of the template or retrieved in a seperate call to google-play (couldn't find such a call)....

BUILD_NUMBER=$(($(google-play get-latest-build-number --package-name "$PACKAGE_NAME" --tracks="$GOOGLE_PLAY_TRACK") + 1))      
          flutter build appbundle --release \
            --build-name=1.0.CHANGE_THIS_YOURSELF \
            --build-number=$BUILD_NUMBER

Additional context
Note in the screenshot the build number (4) is both the minor version and the build number. this is incorrect, the scripting should have produced 1.02 with a latest version of 4.

Screen Shot 2023-06-30 at 12 17 47 am

Getting support
Support for customers who haven't enabled billing is available in the Discussions section of our Documentation repository.

If you have enabled billing in Codemagic, you can contact the support team directly using the in-app chat widget.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions