Skip to content
This repository was archived by the owner on Mar 31, 2025. It is now read-only.

Commit d23fef6

Browse files
committed
Change scope of required libraries to "compile"
1 parent c489551 commit d23fef6

1 file changed

Lines changed: 11 additions & 0 deletions

File tree

build.gradle

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,17 @@ publishing {
131131
}
132132
}
133133

134+
//we have to change scope from runtime to compile. especially for Gson-lib.
135+
publishing.publications.all {
136+
pom.withXml {
137+
asNode().dependencies.'*'.findAll() {
138+
it.scope.text() == 'runtime' && project.configurations.compile.allDependencies.find { dep ->
139+
dep.name == it.artifactId.text()
140+
}
141+
}.each { it.scope*.value = 'compile'}
142+
}
143+
}
144+
134145
bintray {
135146
user = project.hasProperty('bintrayUser') ? project.property('bintrayUser') : System.getenv('BINTRAY_USER')
136147
key = project.hasProperty('bintrayApiKey') ? project.property('bintrayApiKey') : System.getenv('BINTRAY_API_KEY')

0 commit comments

Comments
 (0)