Skip to content

Commit

Permalink
breaking change: support for Gradle 8.0 (#41)
Browse files Browse the repository at this point in the history
* Update artifact-javadoc-handler.gradle

* fix: use archiveClassifier
  • Loading branch information
gotev authored Jul 9, 2023
1 parent cd04263 commit 1af500d
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions artifact-javadoc-handler.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,12 @@ if (isAndroidProject()) {
}

task androidJavadocsJar(type: Jar, dependsOn: androidJavadocs) {
classifier = 'javadoc'
archiveClassifier = 'javadoc'
from androidJavadocs.destinationDir
}

task androidSourcesJar(type: Jar) {
classifier = 'sources'
archiveClassifier = 'sources'
from android.sourceSets.main.java.srcDirs
}
} else {
Expand Down
8 changes: 4 additions & 4 deletions artifact-pom-manager.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ def addDependencies(pom) {

if (dep.artifacts.size() > 0) {
dep.artifacts.each { art ->
addDependencyNode(dependenciesNode, dep, scope, art.classifier, art.extension)
addDependencyNode(dependenciesNode, dep, scope, art.archiveClassifier, art.extension)
}
} else {
addDependencyNode(dependenciesNode, dep, scope, null, null)
Expand All @@ -50,14 +50,14 @@ def addDependencies(pom) {
}
}

def addDependencyNode(dependenciesNode, dep, scope, classifier, extension) {
def addDependencyNode(dependenciesNode, dep, scope, archiveClassifier, extension) {
final dependencyNode = dependenciesNode.appendNode('dependency')
dependencyNode.appendNode('groupId', dep.group)
dependencyNode.appendNode('artifactId', dep.name)
dependencyNode.appendNode('version', dep.version)

if (classifier != null) {
dependencyNode.appendNode('classifier', classifier)
if (archiveClassifier != null) {
dependencyNode.appendNode('archiveClassifier', archiveClassifier)
}

if (extension != null) {
Expand Down

0 comments on commit 1af500d

Please sign in to comment.