Skip to content

[gradle-plugin] Simplify task wiring #6562

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

Merged
merged 1 commit into from
Jun 11, 2025
Merged

Conversation

martinbonnin
Copy link
Contributor

@martinbonnin martinbonnin commented Jun 11, 2025

registerJavaGeneratingTask() works for Kotlin sources as well, no need to distinguish the cases. Fixes connectToAndroidSourceSet that broke with #6442.

As a workaround until this is released, you can set up explicit dependencies:

apollo {
    service("service") {
        packageName.set("com.example")
        outputDirConnection {
            tasks.withType(KotlinCompile::class.java).configureEach {
                dependsOn(task)
            }
            connectToAndroidSourceSet("main")
        }
    }
}

@martinbonnin martinbonnin requested a review from BoD as a code owner June 11, 2025 09:30
Copy link
Contributor

@BoD BoD left a comment

Choose a reason for hiding this comment

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

👍

@martinbonnin martinbonnin merged commit 5728c76 into main Jun 11, 2025
6 checks passed
@martinbonnin martinbonnin deleted the simplify-task-wiring branch June 11, 2025 13:23
martinbonnin added a commit that referenced this pull request Jun 11, 2025
martinbonnin added a commit that referenced this pull request Jun 11, 2025
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.

2 participants