bugsnag / bugsnag-android-gradle-plugin

Gradle plugin for BugSnag which uploads ProGuard, DexGuard and NDK mapping files, and sends build notifications
https://docs.bugsnag.com/build-integrations/gradle/
MIT License
70 stars 38 forks source link

Fix task ordering for AGP 3 #441

Closed lemnik closed 3 years ago

lemnik commented 3 years ago

Goal

Fix projects using Android Gradle Plugin 3.5 with Proguard by ensuring that our generation and upload tasks run after the main build process has been completed.

Design

Due to how the Proguard mapping.txt is handled in AGP < 4 we need to manually enforce a task ordering to ensure that our Proguard generation and upload tasks run after the mapping.txt is actually generated.

Testing

ReactNative Monorepo fixture configured for enableProguardInReleaseBuilds. Manual testing with various versions of AGP and ReactNative projects.