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

make it possible to use configure with the main plugin #680

Merged
merged 1 commit into from
Dec 10, 2023

Conversation

gabrielittner
Copy link
Collaborator

This brings 2 changes:

The tests run through without an issue, so moving the automatic KMP configuration to afterEvaluate doesn't seem to have any issues. In the first place I only moved it out of afterEvaluate in #351 so that it runs before the Android configuration in finalizeDsl. That's not really needed since we can just do the KMP configuration in finalizeDsl as well and then no-op in afterEvaluate if the platform was already configured.

Comment on lines -55 to -58
### Android Library (multiple variants)

For projects using the `com.android.library` plugin. This will publish all variants of the project (e.g. both
`debug` and `release`) or a subset of specified variants.
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Old docs for each platform have been moved to what.md

- [`java-platform`](#java-platform)
- [`version-catalog`](#version-catalog)

## Android Library (multiple variants)
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

From here on this is a 1:1 copy of what used to be in base.md

@@ -178,7 +178,6 @@ private fun writeSettingFile(path: Path) {
dependencyResolutionManagement {
repositories {
mavenLocal()
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Having this made Kotlin/JS compilation fail for some reason https://youtrack.jetbrains.com/issue/KT-61760, fortunately we don't need it.

* Calls [configure] with a [Platform] chosen based on other applied Gradle plugins.
*/
@Incubating
fun configureBasedOnAppliedPlugins() {
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

We could allow optionally passing javadocJar: JavadocJar? = null, sourcedJar: Boolean = true (null = we use our current logic) here to eliminate many use cases of calling configure. Only weird thing about this would be that some platforms would ignore the option if it doesn't apply or is not configurable for it.

@gabrielittner gabrielittner merged commit 0b43d7f into main Dec 10, 2023
12 checks passed
@gabrielittner gabrielittner deleted the configure branch December 10, 2023 14:45
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.

Getting "The value for this property is final and cannot be changed any further"
2 participants