Class ArtifactEntry
java.lang.Object
io.github.intisy.gradle.github.extension.ArtifactEntry
A single JAR artifact to include in a GitHub release.
Configure multiple entries inside a publishGithub { artifacts { } } block:
publishGithub {
artifacts {
artifact {
jar = file("build/libs/my-lib.jar")
classifier = "" // default artifact — uploaded as repo.jar
}
artifact {
jar = file("build/libs/my-lib-api.jar")
classifier = "api" // uploaded as repo-api.jar
}
}
}
A blank or null classifier produces the asset name repo.jar.
Any other classifier produces repo-CLASSIFIER.jar.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetJar()voidsetClassifier(String classifier) Sets the classifier that distinguishes this artifact from others in the same release.voidSets the JAR file to upload for this artifact.
-
Constructor Details
-
ArtifactEntry
public ArtifactEntry()
-
-
Method Details
-
setJar
Sets the JAR file to upload for this artifact.- Parameters:
jar- the JAR file
-
getJar
- Returns:
- the JAR file to upload, or null if not set
-
setClassifier
Sets the classifier that distinguishes this artifact from others in the same release. A blank or null classifier makes this the default artifact (repo.jar).- Parameters:
classifier- the classifier string, e.g."api","fat"
-
getClassifier
- Returns:
- the classifier, or an empty string for the default artifact
-