Skip to content

Commit

Permalink
deps: Update cyclonedx-core-java to version 8.0.0
Browse files Browse the repository at this point in the history
This deprecates the `Tool` class in favor of `ToolInformation`, see [1].

[1]: CycloneDX/cyclonedx-core-java#316
  • Loading branch information
renovate[bot] authored and sschuberth committed Oct 4, 2023
1 parent 3207d1e commit 9dd231f
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 8 deletions.
2 changes: 1 addition & 1 deletion gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ asciidoctorjPdf = "2.3.9"
clikt = "4.2.0"
commonsCompress = "1.24.0"
cvssCalculator = "1.4.2"
cyclonedx = "7.3.2"
cyclonedx = "8.0.0"
diffUtils = "4.12"
diskLruCache = "2.0.2"
exposed = "0.44.0"
Expand Down
17 changes: 10 additions & 7 deletions plugins/reporters/cyclonedx/src/main/kotlin/CycloneDxReporter.kt
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ import org.cyclonedx.model.Hash
import org.cyclonedx.model.License
import org.cyclonedx.model.LicenseChoice
import org.cyclonedx.model.Metadata
import org.cyclonedx.model.Tool
import org.cyclonedx.model.metadata.ToolInformation

import org.ossreviewtoolkit.model.FileFormat
import org.ossreviewtoolkit.model.LicenseSource
Expand Down Expand Up @@ -155,12 +155,15 @@ class CycloneDxReporter : Reporter {

val metadata = Metadata().apply {
timestamp = Date()
tools = listOf(
Tool().apply {
name = ORT_FULL_NAME
version = Environment.ORT_VERSION
}
)
toolChoice = ToolInformation().apply {
components = listOf(
Component().apply {
type = Component.Type.APPLICATION
name = ORT_FULL_NAME
version = Environment.ORT_VERSION
}
)
}
licenseChoice = LicenseChoice().apply { expression = dataLicense }
}

Expand Down

0 comments on commit 9dd231f

Please sign in to comment.