Skip to content

Commit

Permalink
Configure generation of schema in generate-sources
Browse files Browse the repository at this point in the history
  • Loading branch information
algomaster99 committed Aug 17, 2023
1 parent 4e61eea commit b7fd40e
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 31 deletions.
18 changes: 18 additions & 0 deletions terminator-commons/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,24 @@
<groupId>com.diffplug.spotless</groupId>
<artifactId>spotless-maven-plugin</artifactId>
</plugin>
<plugin>
<groupId>org.jsonschema2pojo</groupId>
<artifactId>jsonschema2pojo-maven-plugin</artifactId>
<version>1.2.1</version>
<configuration>
<sourceDirectory>${basedir}/src/main/resources/schema</sourceDirectory>
<targetPackage>io.github.algomaster99.terminator.cyclonedx</targetPackage>
<includes>*.json</includes>
</configuration>
<executions>
<execution>
<goals>
<goal>generate</goal>
</goals>
<phase>generate-sources</phase>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>
31 changes: 0 additions & 31 deletions terminator-commons/src/main/resources/schema/bom-1.4.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -96,11 +96,6 @@
"uniqueItems": true,
"title": "Vulnerabilities",
"description": "Vulnerabilities identified in components or services."
},
"signature": {
"$ref": "#/definitions/signature",
"title": "Signature",
"description": "Enveloped signature in [JSON Signature Format (JSF)](https://cyberphone.github.io/doc/security/jsf.html)."
}
},
"definitions": {
Expand Down Expand Up @@ -467,11 +462,6 @@
"description": "Provides the ability to document properties in a name-value store. This provides flexibility to include data not officially supported in the standard without having to use additional namespaces or create extensions. Unlike key-value stores, properties support duplicate names, each potentially having different values. Property names of interest to the general public are encouraged to be registered in the [CycloneDX Property Taxonomy](https://github.com/CycloneDX/cyclonedx-property-taxonomy). Formal registration is OPTIONAL.",
"additionalItems": false,
"items": {"$ref": "#/definitions/property"}
},
"signature": {
"$ref": "#/definitions/signature",
"title": "Signature",
"description": "Enveloped signature in [JSON Signature Format (JSF)](https://cyberphone.github.io/doc/security/jsf.html)."
}
}
},
Expand Down Expand Up @@ -610,12 +600,6 @@
],
"additionalProperties": false,
"properties": {
"id": {
"$ref": "spdx.schema.json",
"title": "License ID (SPDX)",
"description": "A valid SPDX license ID",
"examples": ["Apache-2.0"]
},
"name": {
"type": "string",
"title": "License Name",
Expand Down Expand Up @@ -1018,11 +1002,6 @@
"description": "Provides the ability to document properties in a name-value store. This provides flexibility to include data not officially supported in the standard without having to use additional namespaces or create extensions. Unlike key-value stores, properties support duplicate names, each potentially having different values. Property names of interest to the general public are encouraged to be registered in the [CycloneDX Property Taxonomy](https://github.com/CycloneDX/cyclonedx-property-taxonomy). Formal registration is OPTIONAL.",
"additionalItems": false,
"items": {"$ref": "#/definitions/property"}
},
"signature": {
"$ref": "#/definitions/signature",
"title": "Signature",
"description": "Enveloped signature in [JSON Signature Format (JSF)](https://cyberphone.github.io/doc/security/jsf.html)."
}
}
},
Expand Down Expand Up @@ -1124,11 +1103,6 @@
},
"title": "BOM references",
"description": "The bom-ref identifiers of the components or services being described. Dependencies refer to a relationship whereby an independent constituent part requires another independent constituent part. References do not cascade to transitive dependencies. References are explicit for the specified dependency only."
},
"signature": {
"$ref": "#/definitions/signature",
"title": "Signature",
"description": "Enveloped signature in [JSON Signature Format (JSF)](https://cyberphone.github.io/doc/security/jsf.html)."
}
}
},
Expand Down Expand Up @@ -1687,11 +1661,6 @@
"type": "string",
"minLength": 1,
"maxLength": 1024
},
"signature": {
"$ref": "jsf-0.82.schema.json#/definitions/signature",
"title": "Signature",
"description": "Enveloped signature in [JSON Signature Format (JSF)](https://cyberphone.github.io/doc/security/jsf.html)."
}
}
}

0 comments on commit b7fd40e

Please sign in to comment.