Skip to content

Commit 72b5bb1

Browse files
author
Vincent Gachet
committed
Fix pom file error
1 parent 3f9c2b1 commit 72b5bb1

File tree

2 files changed

+23
-6
lines changed

2 files changed

+23
-6
lines changed

gradle.properties

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,6 @@
1717
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
1818
# org.gradle.parallel=true
1919

20-
projectversion = 1.0.31
21-
22-
publishedgroupid = com.github.vgachet
23-
libraryname = sma_assetmanager
24-
2520
librarydescription = Smartapps asset manager library
2621

2722
siteurl = https://github.com/smartguide

lib_smaassetmanager/build.gradle

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,29 @@ afterEvaluate {
4141
from components.release
4242
groupId = 'com.github.vgachet'
4343
artifactId = 'sma_assetmanager'
44-
version = '1.0.32'
44+
version = '1.0.33'
45+
46+
//The publication doesn't know about our dependencies, so we have to manually add them to the pom
47+
pom.withXml {
48+
// for dependencies and exclusions
49+
def dependenciesNode = asNode().appendNode('dependencies')
50+
configurations.implementation.allDependencies.withType(ModuleDependency) { ModuleDependency dp ->
51+
def dependencyNode = dependenciesNode.appendNode('dependency')
52+
dependencyNode.appendNode('groupId', dp.group)
53+
dependencyNode.appendNode('artifactId', dp.name)
54+
dependencyNode.appendNode('version', dp.version)
55+
56+
// for exclusions
57+
if (dp.excludeRules.size() > 0) {
58+
def exclusions = dependencyNode.appendNode('exclusions')
59+
dp.excludeRules.each { ExcludeRule ex ->
60+
def exclusion = exclusions.appendNode('exclusion')
61+
exclusion.appendNode('groupId', ex.group)
62+
exclusion.appendNode('artifactId', ex.module)
63+
}
64+
}
65+
}
66+
}
4567
}
4668
}
4769
}

0 commit comments

Comments
 (0)