@@ -40,7 +40,9 @@ from [kotlinx.serialization-json](https://github.com/Kotlin/kotlinx.serializatio
40
40
41
41
In order to use releases add Maven Central repository to the list of repositories.
42
42
43
- ##### Kotlin
43
+ ##### Gradle
44
+
45
+ ###### Kotlin
44
46
45
47
``` kotlin
46
48
repositories {
@@ -50,7 +52,7 @@ repositories {
50
52
implementation(" io.github.optimumcode:json-schema-validator:0.5.1" )
51
53
```
52
54
53
- ##### Groovy
55
+ ###### Groovy
54
56
55
57
``` groovy
56
58
repositories {
@@ -68,27 +70,42 @@ implementation("io.github.optimumcode:json-schema-validator")
68
70
_ Release are published to Sonatype repository. The synchronization with Maven Central takes time._
69
71
_ If you want to use the release right after the publication you should add Sonatype Release repository to your build script._
70
72
71
- ##### Kotlin
73
+ ###### Kotlin
72
74
73
75
``` kotlin
74
76
repositories {
75
77
maven(url = " https://s01.oss.sonatype.org/content/repositories/releases/" )
76
78
}
77
79
```
78
80
79
- ##### Groovy
81
+ ###### Groovy
80
82
81
83
``` groovy
82
84
repositories {
83
85
maven { url 'https://s01.oss.sonatype.org/content/repositories/releases/' }
84
86
}
85
87
```
86
88
89
+ ##### Maven
90
+
91
+ You can also use ` json-schema-validator ` as a dependency in your maven project.
92
+ But Maven cannot use Gradle's metadata so you need to depend on a JVM-specific artifact in your project:
93
+
94
+ ``` xml
95
+ <dependency >
96
+ <groupId >io.github.optimumcode</groupId >
97
+ <artifactId >json-schema-validator-jvm</artifactId >
98
+ <version >0.5.1</version >
99
+ </dependency >
100
+ ```
101
+
87
102
#### Snapshots
88
103
89
104
_ If you want to use SNAPSHOT version you should add Sonatype Snapshot repository to your build script._
90
105
91
- ##### Kotlin
106
+ ##### Gradle
107
+
108
+ ###### Kotlin
92
109
93
110
``` kotlin
94
111
repositories {
@@ -103,7 +120,7 @@ implementation(platform("io.github.optimumcode:json-schema-validator-bom:0.5.2-S
103
120
implementation(" io.github.optimumcode:json-schema-validator" )
104
121
```
105
122
106
- ##### Groovy
123
+ ###### Groovy
107
124
108
125
``` groovy
109
126
repositories {
@@ -113,6 +130,36 @@ repositories {
113
130
implementation 'io.github.optimumcode:json-schema-validator:0.5.2-SNAPSHOT'
114
131
```
115
132
133
+ ##### Maven
134
+
135
+ For the Maven you need to add a snapshot repository to your POM file
136
+
137
+ ``` xml
138
+ <repositories >
139
+ <repository >
140
+ <id >sonatype</id >
141
+ <name >sonatype-snapshot</name >
142
+ <url >https://s01.oss.sonatype.org/content/repositories/snapshots/</url >
143
+ <snapshots >
144
+ <enabled >true</enabled >
145
+ </snapshots >
146
+ <releases >
147
+ <enabled >false</enabled >
148
+ </releases >
149
+ </repository >
150
+ </repositories >
151
+ ```
152
+
153
+ And then you can add a dependency to a SNAPSHOT version
154
+
155
+ ``` xml
156
+ <dependency >
157
+ <groupId >io.github.optimumcode</groupId >
158
+ <artifactId >json-schema-validator-jvm</artifactId >
159
+ <version >0.5.2-SNAPSHOT</version >
160
+ </dependency >
161
+ ```
162
+
116
163
### Example
117
164
118
165
If you have just one JSON schema or many independent schemes
0 commit comments