Skip to content

Conversation

@mravn-google
Copy link
Contributor

@mravn-google mravn-google commented Jun 23, 2017

Introduce use of gradle wrapper in project template to ensure repeatable builds. Manage gradle wrapper scripts and binary using Flutter tool cache. Update gradle and android gradle plugin versions to address #9842 and #10236.

Notes:

  • Upgrades new Flutter projects to use gradle wrapper + gradle version 3.3 + android gradle plugin version 2.3.3. This is the configuration used by Android Studio in latest stable version 2.3.3.
  • PR is morally a retake of Add gradle wrapper to new project template. #9882, but without distributing the gradle wrapper scripts and binaries using the Flutter repo. Instead, these files are managed by the cache, similar to the engine dependency.
  • cache.dart has been refactored to avoid duplication across now three cached artifacts (material fonts, engine, gradle wrapper).
  • There should be no implications for existing Flutter projects.
  • New projects will get the standard complement of gradle wrapper files in their android folder. These files should be checked into version control.
  • Document template files in README.md #10927 is left for a separate task.

@mravn-google
Copy link
Contributor Author

cc @abarth @Hixie

Copy link
Member

@mit-mit mit-mit left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@@ -0,0 +1 @@
0b5c1398d1d04ac245a310de98825cb7b3278e2a
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we add a comment in this file describing just what this version is used for?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That could trip up parsing. The version files for engine and material fonts do not include such a comment; file name says it all I guess.

Copy link
Contributor

@jakobr-google jakobr-google left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

if (location.existsSync())
location.deleteSync(recursive: true);
location.createSync(recursive: true);
return updateInner().then<Null>((Null value) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

_ instead of Null value?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants