-
Notifications
You must be signed in to change notification settings - Fork 29.7k
reads min/target sdk versions from localproperties #98450
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
reads min/target sdk versions from localproperties #98450
Conversation
camsim99
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To be consistent with #95684
|
How to set this properties on CI server? the |
|
PTAL @christopherfujino |
|
This pull request is not suitable for automatic merging in its current state.
|
christopherfujino
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
|
quick question do i just add the values in the flutter.buildMode=debug
flutter.versionName=1.0.0
flutter.versionCode=1
flutter.minSdkVersion=19
flutter.targetSdkVersion=31
flutter.compileSdkVersion=33like so or i'm missing something ? |
|
@SPiercer Looks like this change was reverted in #99191. You can update the |
This PR changes the
build.gradlefiles to read theflutter.minSdkVersionandflutter.targetSdkVersionfrom the generated local.properties, and if not found, keep the default one (which is set at flutter.gradle)It changes all
build.gradlefiles from examples/* and the integration_test/example.It doesn't change
build.gradlefiles from dev projects at dev/* but they can be changed too upon further request.It changes both java and kotlin
build.gradletemplates.It changes the default app test to expect the new strings on
build.gradle.It doesn't apply the same concept to
flutter.compileSdkVersion, so having it onlocal.propertiesdoesn't change the value set atflutter.gradle, this can also be added upon further request.This PR also changes
flutter.gradleto detect and warn the developer with alogger.quietmessage about mismatches with plugins API level. If a mismatch is found, it also checks if the variablesflutter.minSdkVersionandflutter.targetSdkVersionwere set atlocal.propertiesIt also changes the
gradle_errors.dartto update the box message about how to fix the API level error, while adding a reference to the docs. The test was also updated.Images:
[Before] New project with a dependency requiring higher sdk version.
[After] New project with a dependency requiring higher sdk version.
[After] New project with the variables INcorrectly set at local.properties.
[After] New project with the variables correctly set at local.properties.
It closes #95533
Partially solves #95485 (Android part)
Could be a solution to #95514
Extra - Not related: at 0440790 I fixed the command required to export the
FLUTTER_ROOTvariable in order to run tests.