Reputation: 4325
I am trying to build appbundle in my project. I follow steps from official guide but getting following error on gradle sync. What can be wrong?
* What went wrong:
A problem occurred evaluating project ':MyProject'.
> Could not find method bundle() for arguments [build_4ng76ykxfhsfa1nuepa3fikmu$_run_closure5$_closure28@6448fs70] on object of type com.android.build.gradle.AppExtension.
I added android.enableAapt2=true
to gradle.properties file and run ./gradlew --stop
Upvotes: 3
Views: 3474
Reputation: 4325
I missed plugin version, If someone face same stacktrace. Please check plugin version.
Update Android gradle plugin version to
3.2.0
or laterclasspath "com.android.tools.build:gradle:3.2.0"
Upvotes: 1
Reputation: 1
signingConfigs {
debug {
keyAlias 'xxxxxx'
keyPassword 'xxxxx'
storeFile file('xxxxx')
storePassword 'xxxxx'
}
releaseConfig {}
}
you maybe lost signingConfigs {} which is the curly braces, i add this then anything is well.
you may try it
Upvotes: 0
Reputation: 17397
I believe the task you're looking for is bundleRelease
or bundleDebug
.
Upvotes: 0