Skip to content

Commit

Permalink
Merge pull request #102 from bric3/central-validation-failure-fixes
Browse files Browse the repository at this point in the history
central validation failure fixes
  • Loading branch information
bric3 authored Aug 18, 2022
2 parents d044a32 + 5819472 commit f2bb38e
Show file tree
Hide file tree
Showing 8 changed files with 42 additions and 30 deletions.
45 changes: 24 additions & 21 deletions build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -56,16 +56,17 @@ tasks.create("v") {
}
}

val fireplaceModules = subprojects.filter { it.name != projects.fireplaceApp.name }
val fireplaceModules = subprojects - project(":fireplace-app") - project(":fireplace-swt-experiment")
configure(fireplaceModules) {
apply(plugin = "java-library") // needed to get the java component
apply(plugin = "maven-publish")
apply(plugin = "signing")
apply(plugin = "biz.aQute.bnd.builder")

// configure<JavaPluginExtension> {
// withSourcesJar()
// }
configure<JavaPluginExtension> {
withJavadocJar()
withSourcesJar()
}

repositories {
mavenCentral()
Expand All @@ -84,15 +85,6 @@ configure(fireplaceModules) {
metaInf.with(licenseSpec)
}

// todo replace by java.withSourcesJar()
val sourcesJar by registering(Jar::class) {
archiveClassifier.set("sources")
from(
// take extension from project instance
project.the<SourceSetContainer>().named("main").get().allJava
)
}

val jar = named<Jar>("jar") {
bundle {
val version by archiveVersion
Expand Down Expand Up @@ -138,9 +130,7 @@ configure(fireplaceModules) {
publications {
create<MavenPublication>("mavenJava") {
from(components["java"])
artifact(tasks["sourcesJar"])
groupId = project.group.toString()
artifactId = project.name

// OSSRH enforces the `-SNAPSHOT` suffix on snapshot repository
// https://central.sonatype.org/faq/400-error/#question
version = when {
Expand All @@ -149,19 +139,17 @@ configure(fireplaceModules) {
}
project.extra["publishingVersion"] = version

afterEvaluate {
description = project.description
}

val gitRepo = "https://github.com/bric3/fireplace"
pom {
name.set(project.name)
url.set(gitRepo)

scm {
connection.set("scm:git:${gitRepo}.git")
developerConnection.set("scm:git:${gitRepo}.git")
url.set(gitRepo)
}

issueManagement {
system.set("GitHub")
url.set("https://github.com/spring-projects/spring-framework/issues")
Expand All @@ -174,7 +162,23 @@ configure(fireplaceModules) {
url.set("https://www.mozilla.org/en-US/MPL/2.0/")
}
}

developers {
developer {
id.set("bric3")
name.set("Brice Dutheil")
email.set("[email protected]")
}
}
}
// subprojects properties (like description) will be available
// after they have been configured
afterEvaluate {
pom {
description.set(project.description)
}
}

}
}
repositories {
Expand All @@ -195,7 +199,6 @@ configure(fireplaceModules) {
url = uri("${rootProject.buildDir}/publishing-repository")
}
project.extra["publishingRepositoryUrl"] = url

}
}
}
Expand Down
2 changes: 2 additions & 0 deletions fireplace-app/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@

fun properties(key: String) = project.findProperty(key).toString()

description = "Swing app that uses fireplace-swing"

plugins {
id("application")
id("com.github.johnrengelman.shadow") version "7.1.2"
Expand Down
2 changes: 2 additions & 0 deletions fireplace-swing-animation/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/
description = "Animate zoom transitions of a flamegraph or iciclegraph swing component"

dependencies {
implementation(projects.fireplaceSwing)
implementation(libs.radiance.animation)
Expand Down
2 changes: 2 additions & 0 deletions fireplace-swing/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/
description = "Flamegraph or iciclegraph swing component"

plugins {
`jvm-test-suite`
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@
*
* ImageIO.write(image, "png", new File("flamegraph.png"));
* </code></pre>
* </p>
*
* @param <T> The type of the node data.
* @see FlamegraphView
Expand All @@ -61,7 +60,6 @@ public class FlamegraphImage<T> {
* like the type of events, their number, etc.</li>
* <li>The frame background and foreground colors</li>
* </ul>
* </p>
*
* @param frameTextsProvider The function to display label in frames.
* @param frameColorProvider The frame to background color function.
Expand Down Expand Up @@ -132,11 +130,11 @@ public RenderedImage generate(FrameModel<T> frameModel, FlamegraphView.Mode mode
* And finally, the renderer will use the graphics handle to draw the graph.
* </p>
*
* @param frameModel The frame model to render.
* @param mode The display mode of the graph.
* @param width The wanted width of the image, the height is computed from this width.
* @param g2 The graphics context to render to.
* @param onHeightComputed Callback when the height has been computed.
* @param frameModel The frame model to render.
* @param mode The display mode of the graph.
* @param width The wanted width of the image, the height is computed from this width.
* @param g2 The graphics context to render to.
* @param onHeightComputed Callback when the height has been computed.
*/
public void generate(
FrameModel<T> frameModel,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@
* )
* )
* </code></pre>
* </p>
*
* <p>
* The created and <em>final</em> {@code component} is a composite that is based
* on a {@link JScrollPane}.
Expand Down Expand Up @@ -290,6 +290,8 @@ public void setBackground(Color bg) {

/**
* Experimental configuration hook for the underlying canvas.
*
* @param canvasConfigurer The configurer for the canvas.
*/
public void configureCanvas(Consumer<JComponent> canvasConfigurer) {
Objects.requireNonNull(canvasConfigurer).accept(canvas);
Expand Down Expand Up @@ -490,7 +492,7 @@ public void setSelectedFrameConsumer(BiConsumer<FrameBox<T>, MouseEvent> consume
public void setHoverListener(HoverListener<T> hoverListener) {
scrollPaneListener.setHoverListener(hoverListener);
}

/**
* Sets the {@link FrameModel}.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ public FrameModel(List<FrameBox<T>> frames) {
* which is referred to as <em>node</em>.
* </p>.
*
* @param title The title of the flamegraph, used in the root frame.
* @param frameEquality Custom equality code for the actual node object {@code T}.
* @param frames The list of {@code FrameBox} objects.
*/
Expand Down
2 changes: 2 additions & 0 deletions fireplace-swt-experiment/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ import org.gradle.nativeplatform.platform.internal.DefaultNativePlatform

fun properties(key: String) = project.findProperty(key).toString()

description = "SWT app that uses fireplace-swing"

plugins {
id("application")
}
Expand Down

0 comments on commit f2bb38e

Please sign in to comment.