@@ -23,7 +23,7 @@ plugins {
23
23
id ' com.github.jk1.dependency-license-report' version ' 2.1'
24
24
id " com.github.hierynomus.license" version " 0.16.1"
25
25
id ' org.asciidoctor.jvm.convert' version ' 3.3.2'
26
- id " org.ajoberstar.git-publish" version " 3.0.0 "
26
+ id " org.ajoberstar.git-publish" version " 4.1.1 "
27
27
}
28
28
29
29
if (JavaVersion . current() != JavaVersion . VERSION_11 ) {
@@ -178,40 +178,37 @@ gitPublish {
178
178
repoUri = ' https://github.com/beryx/badass-jlink-plugin.git'
179
179
branch = ' gh-pages'
180
180
181
- contents {
182
- def pgType = project. hasProperty(' ghPageType' ) ? ghPageType : ' latest'
183
- if (pgType == ' init' ) {
184
- from file(" ghpages" )
185
- } else if (pgType == ' list' ) {
186
- from file(" build/release-list" )
187
- } else {
188
- from file(" ${ asciidoctor.outputDir.path} /html5" )
189
- from file(" build/docs" )
190
- }
191
- def docDir = Boolean . valueOf(badassJlinkPluginReleaseBuild) ? ' releases' : ' snapshots'
192
- if (pgType == ' init' ) {
193
- into " ."
194
- } else if (pgType == ' list' ) {
195
- into " ."
196
- preserve {
197
- include ' **'
198
- exclude " releases.md"
199
- }
200
- } else if (pgType == ' version' ) {
201
- gitPublishPush. enabled = (docDir != ' snapshots' )
202
- into " $docDir /$badassJlinkPluginVersion "
203
-
204
- preserve {
205
- include ' **'
206
- exclude " $docDir /$badassJlinkPluginVersion "
207
- }
208
- } else {
209
- into " $docDir /latest"
181
+ def pgType = project. hasProperty(' ghPageType' ) ? ghPageType : ' latest'
182
+ if (pgType == ' init' ) {
183
+ contents .from file(" ghpages" )
184
+ } else if (pgType == ' list' ) {
185
+ contents. from file(" build/release-list" )
186
+ } else {
187
+ contents. from file(" ${ asciidoctor.outputDir.path} /html5" )
188
+ contents. from file(" build/docs" )
189
+ }
210
190
211
- preserve {
212
- include ' **'
213
- exclude " $docDir /latest"
214
- }
191
+ def docDir = Boolean . valueOf(badassJlinkPluginReleaseBuild) ? ' releases' : ' snapshots'
192
+ if (pgType == ' init' ) {
193
+ contents. into " ."
194
+ } else if (pgType == ' list' ) {
195
+ contents. into " ."
196
+ preserve {
197
+ include ' **'
198
+ exclude " releases.md"
199
+ }
200
+ } else if (pgType == ' version' ) {
201
+ gitPublishPush. enabled = (docDir != ' snapshots' )
202
+ contents. into " $docDir /$badassJlinkPluginVersion "
203
+ preserve {
204
+ include ' **'
205
+ exclude " $docDir /$badassJlinkPluginVersion "
206
+ }
207
+ } else {
208
+ contents. into " $docDir /latest"
209
+ preserve {
210
+ include ' **'
211
+ exclude " $docDir /latest"
215
212
}
216
213
}
217
214
}
0 commit comments