Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
F
Front-End
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
abdullh.alsoleman
Front-End
Commits
d155bc1b
Unverified
Commit
d155bc1b
authored
Jul 26, 2022
by
Zachary Anderson
Committed by
GitHub
Jul 26, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Revert "Upgrade Gradle and AGP versions to 7.5/7.2 and migrate examples/tests (#108197)" (#108349)
This reverts commit
ca6cecf0
.
parent
ca6cecf0
Changes
22
Hide whitespace changes
Inline
Side-by-side
Showing
22 changed files
with
33 additions
and
33 deletions
+33
-33
build.gradle
dev/benchmarks/complex_layout/android/build.gradle
+1
-1
build.gradle
dev/benchmarks/macrobenchmarks/android/build.gradle
+1
-1
build.gradle
dev/benchmarks/microbenchmarks/android/build.gradle
+1
-1
build.gradle
dev/benchmarks/platform_views_layout/android/build.gradle
+1
-1
build.gradle
...form_views_layout_hybrid_composition/android/build.gradle
+1
-1
build.gradle
dev/benchmarks/test_apps/stocks/android/build.gradle
+1
-1
build.gradle
dev/integration_tests/android_views/android/build.gradle
+1
-1
build.gradle
...ation_tests/deferred_components_test/android/build.gradle
+1
-1
build.gradle
dev/integration_tests/flutter_gallery/android/build.gradle
+1
-1
build.gradle
examples/api/android/build.gradle
+1
-1
build.gradle
examples/flutter_view/android/build.gradle
+1
-1
build.gradle
examples/hello_world/android/build.gradle
+1
-1
build.gradle
examples/image_list/android/build.gradle
+1
-1
build.gradle
examples/layers/android/build.gradle
+1
-1
build.gradle
examples/platform_channel/android/build.gradle
+1
-1
build.gradle
examples/platform_view/android/build.gradle
+1
-1
gradle_utils.dart
packages/flutter_tools/lib/src/android/gradle_utils.dart
+6
-6
gradle_errors_test.dart
..._tools/test/general.shard/android/gradle_errors_test.dart
+2
-2
gradle_find_bundle_test.dart
...s/test/general.shard/android/gradle_find_bundle_test.dart
+1
-1
gradle_test.dart
...flutter_tools/test/general.shard/android/gradle_test.dart
+3
-3
gradle_utils_test.dart
...r_tools/test/general.shard/android/gradle_utils_test.dart
+2
-2
android_plugin_example_app_build_test.dart
...egration.shard/android_plugin_example_app_build_test.dart
+3
-3
No files found.
dev/benchmarks/complex_layout/android/build.gradle
View file @
d155bc1b
...
...
@@ -14,7 +14,7 @@ buildscript {
}
dependencies
{
classpath
'com.android.tools.build:gradle:
{{agpVersion}}
'
classpath
'com.android.tools.build:gradle:
7.0.0
'
classpath
"org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
...
...
dev/benchmarks/macrobenchmarks/android/build.gradle
View file @
d155bc1b
...
...
@@ -14,7 +14,7 @@ buildscript {
}
dependencies
{
classpath
'com.android.tools.build:gradle:
{{agpVersion}}
'
classpath
'com.android.tools.build:gradle:
4.1.3
'
classpath
"org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
...
...
dev/benchmarks/microbenchmarks/android/build.gradle
View file @
d155bc1b
...
...
@@ -14,7 +14,7 @@ buildscript {
}
dependencies
{
classpath
'com.android.tools.build:gradle:
{{agpVersion}}
'
classpath
'com.android.tools.build:gradle:
4.1.3
'
classpath
"org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
...
...
dev/benchmarks/platform_views_layout/android/build.gradle
View file @
d155bc1b
...
...
@@ -14,7 +14,7 @@ buildscript {
}
dependencies
{
classpath
'com.android.tools.build:gradle:
{{agpVersion}}
'
classpath
'com.android.tools.build:gradle:
4.1.3
'
classpath
"org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
...
...
dev/benchmarks/platform_views_layout_hybrid_composition/android/build.gradle
View file @
d155bc1b
...
...
@@ -14,7 +14,7 @@ buildscript {
}
dependencies
{
classpath
'com.android.tools.build:gradle:
{{agpVersion}}
'
classpath
'com.android.tools.build:gradle:
4.1.3
'
classpath
"org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
...
...
dev/benchmarks/test_apps/stocks/android/build.gradle
View file @
d155bc1b
...
...
@@ -14,7 +14,7 @@ buildscript {
}
dependencies
{
classpath
'com.android.tools.build:gradle:
{{agpVersion}}
'
classpath
'com.android.tools.build:gradle:
4.1.3
'
classpath
"org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
...
...
dev/integration_tests/android_views/android/build.gradle
View file @
d155bc1b
...
...
@@ -14,7 +14,7 @@ buildscript {
}
dependencies
{
classpath
'com.android.tools.build:gradle:
{{agpVersion}}
'
classpath
'com.android.tools.build:gradle:
4.1.3
'
classpath
"org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
...
...
dev/integration_tests/deferred_components_test/android/build.gradle
View file @
d155bc1b
...
...
@@ -14,7 +14,7 @@ buildscript {
}
dependencies
{
classpath
'com.android.tools.build:gradle:
{{agpVersion}}
'
classpath
'com.android.tools.build:gradle:
4.1.3
'
classpath
"org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
...
...
dev/integration_tests/flutter_gallery/android/build.gradle
View file @
d155bc1b
...
...
@@ -14,7 +14,7 @@ buildscript {
}
dependencies
{
classpath
'com.android.tools.build:gradle:
{{agpVersion}}
'
classpath
'com.android.tools.build:gradle:
4.1.3
'
classpath
"org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
...
...
examples/api/android/build.gradle
View file @
d155bc1b
...
...
@@ -10,7 +10,7 @@ buildscript {
}
dependencies
{
classpath
'com.android.tools.build:gradle:
{{agpVersion}}
'
classpath
'com.android.tools.build:gradle:
4.1.3
'
classpath
"org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
}
...
...
examples/flutter_view/android/build.gradle
View file @
d155bc1b
...
...
@@ -14,7 +14,7 @@ buildscript {
}
dependencies
{
classpath
'com.android.tools.build:gradle:
{{agpVersion}}
'
classpath
'com.android.tools.build:gradle:
4.1.3
'
classpath
"org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
...
...
examples/hello_world/android/build.gradle
View file @
d155bc1b
...
...
@@ -14,7 +14,7 @@ buildscript {
}
dependencies
{
classpath
'com.android.tools.build:gradle:
{{agpVersion}}
'
classpath
'com.android.tools.build:gradle:
4.1.3
'
classpath
"org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
...
...
examples/image_list/android/build.gradle
View file @
d155bc1b
...
...
@@ -14,7 +14,7 @@ buildscript {
}
dependencies
{
classpath
'com.android.tools.build:gradle:
{{agpVersion}}
'
classpath
'com.android.tools.build:gradle:
4.1.3
'
classpath
"org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
...
...
examples/layers/android/build.gradle
View file @
d155bc1b
...
...
@@ -14,7 +14,7 @@ buildscript {
}
dependencies
{
classpath
'com.android.tools.build:gradle:
{{agpVersion}}
'
classpath
'com.android.tools.build:gradle:
4.1.3
'
classpath
"org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
...
...
examples/platform_channel/android/build.gradle
View file @
d155bc1b
...
...
@@ -14,7 +14,7 @@ buildscript {
}
dependencies
{
classpath
'com.android.tools.build:gradle:
{{agpVersion}}
'
classpath
'com.android.tools.build:gradle:
4.1.3
'
classpath
"org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
...
...
examples/platform_view/android/build.gradle
View file @
d155bc1b
...
...
@@ -14,7 +14,7 @@ buildscript {
}
dependencies
{
classpath
'com.android.tools.build:gradle:
{{agpVersion}}
'
classpath
'com.android.tools.build:gradle:
4.1.3
'
classpath
"org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
}
...
...
packages/flutter_tools/lib/src/android/gradle_utils.dart
View file @
d155bc1b
...
...
@@ -27,10 +27,10 @@ import 'android_sdk.dart';
// For more information about the latest version, check:
// https://developer.android.com/studio/releases/gradle-plugin#updating-gradle
// https://kotlinlang.org/docs/gradle.html#plugin-and-versions
const
String
templateDefaultGradleVersion
=
'7.
5
'
;
const
String
templateAndroidGradlePluginVersion
=
'7.
2.0
'
;
const
String
templateDefaultGradleVersionForModule
=
'7.
2.0
'
;
const
String
templateKotlinGradlePluginVersion
=
'1.
7
.10'
;
const
String
templateDefaultGradleVersion
=
'7.
4
'
;
const
String
templateAndroidGradlePluginVersion
=
'7.
1.2
'
;
const
String
templateDefaultGradleVersionForModule
=
'7.
1.2
'
;
const
String
templateKotlinGradlePluginVersion
=
'1.
6
.10'
;
// These versions should match the values in flutter.gradle (FlutterExtension).
// The Flutter Gradle plugin is only applied to app projects, and modules that are built from source
...
...
@@ -204,8 +204,8 @@ String getGradleVersionFor(String androidPluginVersion) {
if
(
_isWithinVersionRange
(
androidPluginVersion
,
min:
'4.0.0'
,
max:
'4.1.0'
))
{
return
'6.7'
;
}
if
(
_isWithinVersionRange
(
androidPluginVersion
,
min:
'7.0'
,
max:
'7.
5
'
))
{
return
'7.
5
'
;
if
(
_isWithinVersionRange
(
androidPluginVersion
,
min:
'7.0'
,
max:
'7.
4
'
))
{
return
'7.
4
'
;
}
throwToolExit
(
'Unsupported Android Plugin version:
$androidPluginVersion
.'
);
}
...
...
packages/flutter_tools/test/general.shard/android/gradle_errors_test.dart
View file @
d155bc1b
...
...
@@ -907,10 +907,10 @@ A problem occurred evaluating project ':app'.
'│ To fix this issue, replace the following content: │
\n
'
'│ /android/build.gradle: │
\n
'
"│ - classpath 'com.android.tools.build:gradle:<current-version>' │
\n
"
"│ + classpath 'com.android.tools.build:gradle:7.
2.0
' │
\n
"
"│ + classpath 'com.android.tools.build:gradle:7.
1.2
' │
\n
"
'│ /android/gradle/wrapper/gradle-wrapper.properties: │
\n
'
'│ - https://services.gradle.org/distributions/gradle-<current-version>-all.zip │
\n
'
'│ + https://services.gradle.org/distributions/gradle-7.
5
-all.zip │
\n
'
'│ + https://services.gradle.org/distributions/gradle-7.
4
-all.zip │
\n
'
'└──────────────────────────────────────────────────────────────────────────────────┘
\n
'
)
);
...
...
packages/flutter_tools/test/general.shard/android/gradle_find_bundle_test.dart
View file @
d155bc1b
...
...
@@ -357,7 +357,7 @@ void main() {
'gradle'
,
label:
'gradle-expected-file-not-found'
,
parameters:
CustomDimensions
.
fromMap
(<
String
,
String
>
{
'cd37'
:
'androidGradlePluginVersion: 7.
5
, fileExtension: .aab'
,
'cd37'
:
'androidGradlePluginVersion: 7.
4
, fileExtension: .aab'
,
}),
),
));
...
...
packages/flutter_tools/test/general.shard/android/gradle_test.dart
View file @
d155bc1b
...
...
@@ -443,9 +443,9 @@ flutter:
expect
(
getGradleVersionFor
(
'4.0.0'
),
'6.7'
);
expect
(
getGradleVersionFor
(
'4.1.0'
),
'6.7'
);
expect
(
getGradleVersionFor
(
'7.0'
),
'7.
5
'
);
expect
(
getGradleVersionFor
(
'7.1.2'
),
'7.
5
'
);
expect
(
getGradleVersionFor
(
'7.2'
),
'7.
5
'
);
expect
(
getGradleVersionFor
(
'7.0'
),
'7.
4
'
);
expect
(
getGradleVersionFor
(
'7.1.2'
),
'7.
4
'
);
expect
(
getGradleVersionFor
(
'7.2'
),
'7.
4
'
);
});
testWithoutContext
(
'throws on unsupported versions'
,
()
{
...
...
packages/flutter_tools/test/general.shard/android/gradle_utils_test.dart
View file @
d155bc1b
...
...
@@ -73,7 +73,7 @@ void main() {
'distributionPath=wrapper/dists
\n
'
'zipStoreBase=GRADLE_USER_HOME
\n
'
'zipStorePath=wrapper/dists
\n
'
'distributionUrl=https
\\
://services.gradle.org/distributions/gradle-7.
5
-all.zip
\n
'
);
'distributionUrl=https
\\
://services.gradle.org/distributions/gradle-7.
4
-all.zip
\n
'
);
});
testWithoutContext
(
'injects the wrapper when some files are missing'
,
()
{
...
...
@@ -110,7 +110,7 @@ void main() {
'distributionPath=wrapper/dists
\n
'
'zipStoreBase=GRADLE_USER_HOME
\n
'
'zipStorePath=wrapper/dists
\n
'
'distributionUrl=https
\\
://services.gradle.org/distributions/gradle-7.
5
-all.zip
\n
'
);
'distributionUrl=https
\\
://services.gradle.org/distributions/gradle-7.
4
-all.zip
\n
'
);
});
testWithoutContext
(
'injects the wrapper and the Gradle version is derivated from the AGP version'
,
()
{
...
...
packages/flutter_tools/test/integration.shard/android_plugin_example_app_build_test.dart
View file @
d155bc1b
...
...
@@ -58,12 +58,12 @@ void main() {
final
RegExp
androidPluginRegExp
=
RegExp
(
r'com\.android\.tools\.build:gradle:(\d+\.\d+\.\d+)'
);
// Use AGP
7.2
.0
// Use AGP
4.1
.0
final
String
newBuildGradle
=
buildGradle
.
replaceAll
(
androidPluginRegExp
,
'com.android.tools.build:gradle:
7.2
.0'
);
androidPluginRegExp
,
'com.android.tools.build:gradle:
4.1
.0'
);
buildGradleFile
.
writeAsStringSync
(
newBuildGradle
);
// Run flutter build apk using AGP
7.2
.0
// Run flutter build apk using AGP
4.1
.0
result
=
processManager
.
runSync
(<
String
>[
flutterBin
,
...
getLocalEngineArguments
(),
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment