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

Add Auto-Manifest plugin #260

Closed
wants to merge 5 commits into from

Conversation

tasomaniac
Copy link

@tasomaniac tasomaniac commented Nov 10, 2020

Fixes #248

Auto-Manifest automatically generates AndroidManifest packageName based on Gradle module structure. Since Splitties has modules and fun-packs separated, it would put modules in the middle of the package. That's why the plugin is applied under modules/build.gradle.kts. This made me realize a small issue on the plugin and released a fix.

One change required in the code (Preview.kt and UiPreview.kt) was that views-dsl used views.dsl.core as packageName and I had to change the imports. Since these imports are not exposed, I don't think it is a breaking change.

Auto-Manifest automatically generates AndroidManifest packageName based on Gradle module structure. Since Splitties has `modules` and `fun-packs` separated, it would put `modules` in the middle of the package. That's why the plugin is applied under `modules/build.gradle.kts`. This made me realize a small issue on the plugin and released a fix.

Once change required in the code was that `views-dsl` used `views.dsl.core` as packageName and I had to change the imports. Since these imports are not exposed, I don't think it is a breaking change.
@tasomaniac
Copy link
Author

It is nice that we have some unnecessary code removal. 84 lines added (unfortunately because I needed to add project param to all gradle files)

build.gradle.kts Outdated Show resolved Hide resolved
@LouisCAD
Copy link
Owner

Can you retarget to the develop branch please?

@tasomaniac tasomaniac changed the base branch from main to develop November 11, 2020 18:40
Copy link
Owner

@LouisCAD LouisCAD left a comment

Choose a reason for hiding this comment

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

Thanks for your PR!
There's a few possible improvements. If you want and have the time, please address them. Otherwise, please tell me and I'll do that myself before merging, no problem.

build.gradle.kts Outdated Show resolved Hide resolved
buildSrc/src/main/kotlin/config/AndroidLibraryConfig.kt Outdated Show resolved Hide resolved
buildSrc/src/main/kotlin/config/AndroidLibraryConfig.kt Outdated Show resolved Hide resolved
modules/views-dsl/src/androidMain/AndroidManifest.xml Outdated Show resolved Hide resolved
versions.properties Show resolved Hide resolved
versions.properties Outdated Show resolved Hide resolved
@LouisCAD
Copy link
Owner

@tasomaniac I think you've seen that the latest build fails (here's the error in the Gradle scan: https://scans.gradle.com/s/vswhzdzwuz6wa/console-log?task=:modules:views-dsl:compileDebugKotlinAndroid)

It looks like the manifest of the views-dsl module is not taken into account.
Is it because auto-manifest assumes the default path for the manifest? Or maybe because something runs too late or too early relative to another thing dealing with the manifest path?

@tasomaniac
Copy link
Author

Hmmm, there are other modules where their manifest is present in the same place. There is nothing special about that module. I will check soon.

@LouisCAD LouisCAD changed the base branch from develop to main July 4, 2021 21:42
@tasomaniac tasomaniac closed this Mar 4, 2022
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.

Replace one-liner AndroidManifest.xml files with the auto-manifest Gradle plugin
2 participants