Skip to content

fix: [ANDROAPP-7018] clean up resource directories in build.gradle.kts #4130

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 2 commits into from
Apr 29, 2025

Conversation

andresmr
Copy link
Collaborator

@andresmr andresmr commented Apr 28, 2025

Description

Remove content duplicate roots

Solution

Remove this line from the commonMain sourceset:
commonMain{ resources.srcDirs("src/commonMain/composeResources") }

Keep only the android source set configuration:
android { sourceSets["main"].res.srcDirs("src/androidMain/res", "src/commonMain/composeResources") }

This will prevent the resource directory from being included twice in different source sets and resolve the warning. The compose resources will still be accessible in your project while avoiding the duplicate resource path issue.

@andresmr andresmr force-pushed the fix-duplicate-content-root branch from 491cfbb to a5c1a44 Compare April 29, 2025 10:39
@andresmr andresmr changed the title fix: clean up resource directories in build.gradle.kts fix: [ANDROAPP-7018] clean up resource directories in build.gradle.kts Apr 29, 2025
@andresmr andresmr merged commit d851c67 into develop Apr 29, 2025
4 checks passed
@andresmr andresmr deleted the fix-duplicate-content-root branch April 29, 2025 13:25
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