Skip to content

Commit 625bc50

Browse files
Reverts "Warn when Gradle plugins are applied using the legacy "apply script method" way" (#140102)
Reverts flutter/flutter#139690 Initiated by: hellohuanlin This change reverts the following previous change: Original Description: This PR adds a deprecation message when Android build is using the legacy "apply script method" way of applying Flutter's Gradle plugins (that is: [`flutter.gradle`](https://github.com/flutter/flutter/blob/3.16.0/packages/flutter_tools/gradle/flutter.gradle) and [`app_plugin_loader.gradle`](https://github.com/flutter/flutter/blob/3.16.0/packages/flutter_tools/gradle/app_plugin_loader.gradle)). See also: - #121541 - in particular flutter/flutter#121541 (comment) - #135392 - and PR that add the migration guide: [flutter#9857](flutter/website#9857) - I think either `logger.error` or `logger.quiet` must be used, because all other error levels are not shown during `flutter build apk` (and that's what most people use).
1 parent c781302 commit 625bc50

File tree

3 files changed

+0
-206
lines changed

3 files changed

+0
-206
lines changed

packages/flutter_tools/gradle/app_plugin_loader.gradle

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,11 +5,5 @@
55
// This file exists solely for the compatibility with projects that have
66
// not migrated to the declarative apply of the Flutter App Plugin Loader Gradle Plugin.
77

8-
logger.error("You are applying Flutter's app_plugin_loader Gradle plugin \
9-
imperatively using the apply script method, which is deprecated and will be \
10-
removed in a future release. Migrate to applying Gradle plugins with the \
11-
declarative plugins block: https://flutter.dev/go/flutter-gradle-plugin-apply\n\
12-
")
13-
148
def pathToThisDirectory = buildscript.sourceFile.parentFile
159
apply from: "$pathToThisDirectory/src/main/groovy/app_plugin_loader.groovy"

packages/flutter_tools/gradle/flutter.gradle

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,5 @@
55
// This file exists solely for the compatibility with projects that have
66
// not migrated to the declarative apply of the Flutter Gradle Plugin.
77

8-
logger.error("You are applying Flutter's main Gradle plugin imperatively using \
9-
the apply script method, which is deprecated and will be removed in a future \
10-
release. Migrate to applying Gradle plugins with the declarative plugins \
11-
block: https://flutter.dev/go/flutter-gradle-plugin-apply\n")
12-
138
def pathToThisDirectory = buildscript.sourceFile.parentFile
149
apply from: "$pathToThisDirectory/src/main/groovy/flutter.groovy"

packages/flutter_tools/test/integration.shard/android_gradle_deprecated_plugin_apply_test.dart

Lines changed: 0 additions & 195 deletions
This file was deleted.

0 commit comments

Comments
 (0)