jsonschema2pojo
54 строки · 1.7 Кб
1plugins {
2id "com.gradle.plugin-publish" version '0.21.0'
3id "java-gradle-plugin"
4id 'maven-publish'
5id "groovy"
6}
7
8repositories {
9mavenCentral()
10mavenLocal()
11}
12
13group = "org.jsonschema2pojo"
14
15if (project.version == 'unspecified')
16throw new GradleException('\n\n!!!!!!!\n\nThe build could not complete as you did not provide a version. This gradle script can build the jsonschema2pojo gradle plugin and push it to plugins.gradle.org, however you must choose what version of jsonschema2pojo to use (and therefore what version of the plugin you are publishing).\n\nPlease include a version as a project property when starting the build, e.g. ./gradlew -Pversion=x.x.x publishPlugins\n\n!!!!!!!')
17
18gradlePlugin {
19plugins {
20jsonschema2pojo {
21id = 'org.jsonschema2pojo'
22implementationClass = 'org.jsonschema2pojo.gradle.JsonSchemaPlugin'
23}
24}
25}
26
27pluginBundle {
28website = 'http://www.jsonschema2pojo.org/'
29vcsUrl = 'https://github.com/joelittlejohn/jsonschema2pojo'
30description = 'Generate Java types from JSON or JSON Schema and annotate those types for data-binding with Jackson, Gson, and more.'
31tags = ['jsonschema', 'jsonschema2pojo', 'json2pojo', 'generation', 'json', 'java', 'pojo']
32
33mavenCoordinates {
34groupId = 'org.jsonschema2pojo'
35artifactId = 'jsonschema2pojo-gradle-plugin'
36}
37
38plugins {
39jsonschema2pojo {
40displayName = 'org.jsonschema2pojo'
41}
42}
43}
44
45sourceCompatibility = '1.8'
46targetCompatibility = '1.8'
47
48dependencies {
49implementation "org.jsonschema2pojo:jsonschema2pojo-core:${project.version}"
50
51testImplementation 'org.hamcrest:hamcrest-all:1.3'
52testImplementation 'junit:junit:4.13.2'
53testImplementation 'org.slf4j:slf4j-simple:1.7.36'
54}
55