Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replaced the buildSrc plugin with discrete build files #2107

Open
wants to merge 2 commits into
base: next
Choose a base branch
from

Conversation

lemnik
Copy link
Contributor

@lemnik lemnik commented Nov 18, 2024

Goal

Break up the build plugin moving the majority of the build logic back into the build.gradle.kts files.

The build plugin within buildSrc created a Gradle classpath structure and plugin application order that has blocked various upgrades (AGP and Kotlin mostly). By splitting up the build plugin and moving to simpler utility functions, we can upgrade components and then migrate more of the build logic back into utilities when/if we can.

Design

The common version details have been rearranged within the Versions object, which now includes a ModuleWithVersion utility class. This serves a similar purpose to a Gradle Version catalog, but can easily be used from within the build sources (buildSrc) and therefore used within utility functions (such as addCommonModuleDependencies() and loadDefaultPlugins()).

Testing

The existing build steps all still work without change. Manually published to Sonatype staging repository.

@bugsnagbot
Copy link
Collaborator

bugsnagbot commented Nov 18, 2024

Android notifier sizes

Format Size impact of Bugsnag (kB) Size impact of Bugsnag when Minified (kB)
APK 1871.56 1675.99
arm64_v8a 647.43 450.82
armeabi_v7a 585.99 385.29
x86 725.23 528.62
x86_64 692.47 495.86

Generated by 🚫 Danger

@lemnik lemnik force-pushed the PLAT-13038/build-rework branch 5 times, most recently from ecdba50 to 3131afd Compare November 18, 2024 15:28
Copy link
Contributor

@tomlongridge tomlongridge left a comment

Choose a reason for hiding this comment

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

LGTM - largely going on looking for inconsistencies and letting the build speak for itself. Seems like a good approach.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants