forked from ho-dev/HattrickOrganizer
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
678 lines (583 loc) · 23.4 KB
/
build.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
//============ plugins and external jar dependencies ===================================================================
plugins {
id "edu.sc.seis.macAppBundle" version "2.2.3"
id "nebula.ospackage" version "5.0.4"
id 'de.jansauer.poeditor' version '1.0.0'
id "org.kordamp.markdown.convert" version "1.2.0"
id "com.github.breadmoirai.github-release" version "2.2.1" apply false
}
// java plugin configuration ========================
apply plugin: 'java'
compileJava.options.encoding = 'UTF-8'
// application plugin configuration ================
apply plugin: 'application'
mainClassName = 'HOLauncher'
repositories {
jcenter()
}
//============ external jar dependencies ==========
dependencies {
compile 'com.google.guava:guava:27.1-jre'
compile 'com.jgoodies:jgoodies-looks:2.7.0'
compile 'com.toedter:jcalendar:1.4'
compile 'org.scribe:scribe:1.3.0'
compile 'org.hsqldb:hsqldb:2.4.1'
compile 'junit:junit:4.12'
compile 'com.google.code.gson:gson:2.8.5'
}
//============ variables ==============================================================================================
//naming
// Major.minor.Development_stage.Build
// Development_stage
// 0 for DEV status
// 1 for BETA status
// 2 for STABLE status
def major = '2'
def minor = '0'
def development_stage = '0'
def releaseArtefacts = false
//====================================================================================================================
def versionPropsFile = file('version.properties')
Properties versionProps = new Properties()
versionProps.load(new FileInputStream(versionPropsFile))
def buildNumber = (versionProps['buildNumber'] as Integer) + 1
buildNumber = buildNumber.toString()
versionProps['buildNumber'] = buildNumber
versionProps.store(versionPropsFile.newWriter(), null)
version = major + '.' + minor + '.' + development_stage + '.' + buildNumber
ext {
nsis_exe_path = "C:\\Program Files (x86)\\NSIS\\makensis.exe"
nsis_confPath = "${projectDir}\\buildResources\\Win\\nsis"
nsis_scriptName = "${nsis_confPath}\\makeWinInstaller.nsi"
target_dir = "${buildDir}\\artefacts"
osx_app_dir_sourcedir = "${projectDir}\\buildResources\\Mac"
python_script = "${projectDir}\\buildResources\\Generic\\generate_hash.py"
}
//======================================================================================================================
// Configure tasks =====================================================================================================
// Configure jar task ================================
jar {
archiveName = "HO.jar"
manifest {
attributes 'Manifest-Version': 1.0, 'Implementation-Title': 'HO', 'Implementation-Version': version,
'Main-Class': 'HOLauncher',
"Class-Path": configurations.compile.collect { it.getName() }.join(' ')
}
// folders
exclude "prediction"
exclude "themes"
// changelog
exclude "changelog.html"
exclude "release_notes.md"
// logos
exclude "ho_logo_stable.png"
exclude "ho_logo_beta.png"
exclude "ho_logo_dev.png"
exclude "Logo_stable.ico"
exclude "Logo_beta.ico"
exclude "Logo_dev.ico"
// external jars
exclude "scribe-1.3.0.jar"
exclude "listenablefuture-9999.0-empty-to-avoid-conflict-with-guava.jar"
exclude "jsr305-3.0.2.jar"
exclude "jgoodies-looks-2.7.0.jar"
exclude "jgoodies-common-1.8.1.jar"
exclude "jcalendar-1.4.jar"
exclude "j2objc-annotations-1.1.jar"
exclude "hsqldb-2.4.1.jar"
exclude "guava-27.1-jre.jar"
exclude "gson-2.8.5.jar"
exclude "failureaccess-1.0.1.jar"
exclude "error_prone_annotations-2.2.0.jar"
exclude "commons-codec-1.4.jar"
exclude "checker-qual-2.5.2.jar"
exclude "animal-sniffer-annotations-1.17.jar"
}
task osXjar(type: Jar) {
archiveName = "HO.jar"
from sourceSets.main.output
manifest {
attributes 'Manifest-Version': 1.0, 'Implementation-Title': 'HO', 'Implementation-Version': version,
'Main-Class': 'HOLauncher',
"Class-Path": configurations.compile.collect { it.getName() }.join(' ')
}
// folders
exclude "prediction"
exclude "themes"
// changelog
exclude "changelog.html"
exclude "release_notes.md"
// logos
exclude "ho_logo_stable.png"
exclude "ho_logo_beta.png"
exclude "ho_logo_dev.png"
exclude "Logo_stable.ico"
exclude "Logo_beta.ico"
exclude "Logo_dev.ico"
// external jars
exclude "scribe-1.3.0.jar"
exclude "listenablefuture-9999.0-empty-to-avoid-conflict-with-guava.jar"
exclude "jsr305-3.0.2.jar"
exclude "jgoodies-looks-2.7.0.jar"
exclude "jgoodies-common-1.8.1.jar"
exclude "jcalendar-1.4.jar"
exclude "j2objc-annotations-1.1.jar"
exclude "hsqldb-2.4.1.jar"
exclude "guava-27.1-jre.jar"
exclude "gson-2.8.5.jar"
exclude "failureaccess-1.0.1.jar"
exclude "error_prone_annotations-2.2.0.jar"
exclude "commons-codec-1.4.jar"
exclude "checker-qual-2.5.2.jar"
exclude "animal-sniffer-annotations-1.17.jar"
}
// Configure distribution task =======================
distributions {
main {
baseName = 'XXX'
}
}
// Configure macAppBundle task =======================
macAppBundle {
mainClassName = "HOLauncher"
icon = "${project.ext.osx_app_dir_sourcedir}\\HO.icns"
bundleJRE = true
javaProperties.put("apple.laf.useScreenMenuBar", "true")
javaProperties.put("apple.awt.showGrowBox", "true")
backgroundImage = "${project.ext.osx_app_dir_sourcedir}\\Back.png"
}
// Configure ospackage and buildDeb tasks ============
ospackage {
packageName = 'ho'
os = LINUX // only applied to RPM
packager 'aksolace'
summary ' HattrickOrganizer! \n Manager tool for http://www.hattrick.org'
license = 'LGPL'
into '/usr'
from(jar.outputs.files) {
into 'lib\\ho'
}
from("${projectDir}\\src\\main\\resources\\sprache") {
into 'lib\\ho\\sprache'
}
from("${projectDir}\\src\\main\\resources\\flags") {
into 'lib\\ho\\flags'
}
from("${projectDir}\\src\\main\\resources\\prediction") {
into 'lib\\ho\\prediction'
}
from("${projectDir}\\src\\main\\resources\\themes") {
into 'lib\\ho\\themes'
}
from("${projectDir}\\src\\main\\resources") {
include "**/*.jar"
into "lib\\ho"
}
from("${projectDir}\\src\\main\\resources") {
if (development_stage == '0') {
include "ho_logo_dev.png"
rename "ho_logo_dev.png", "ho_logo.png"
}
else if (development_stage == '1') {
include "ho_logo_beta.png"
rename "ho_logo_beta.png", "ho_logo.png"
}
else {
include "ho_logo_stable.png"
rename "ho_logo_stable.png", "ho_logo.png"
}
into "lib\\ho"
}
from("${projectDir}\\buildResources\\Linux\\ho.sh") {
into 'bin'
fileMode = 0755
}
from("${projectDir}\\buildResources\\Linux\\ho.desktop") {
into 'share\\applications'
fileMode = 0644
}
postInstall "chmod 777 /usr/lib/ho"
}
buildDeb {
requires("openjdk-8-jre | openjdk-9-jre | openjdk-10-jre | openjdk-11-jre")
link('/usr/bin/ho', '/usr/bin/ho.sh')
}
buildRpm {
requires("jre-1.8.0-openjdk")
link('/usr/bin/ho', '/usr/bin/ho.sh')
}
//======================================================================================================================
// ========== my tasks ================================================================================================
import java.text.SimpleDateFormat
task makeAll(type: GradleBuild) {
group 'ho'
description 'Create ZipDistribution, Windows, MacOS and Linux binaries'
tasks = ['cleanBuild', 'pushmd', 'markdownToHtml', 'pullhtml', 'poeditorPull', 'createLanguageFileList',
'installDist', 'AddResourcesInDistrib', 'makeWinInstaller', 'ZipDistribution', 'buildDeb',
'finishDeb', 'buildRpm', 'finishRpm', 'osXjar', 'createApp', 'AddResourcesAndZipMacApp', 'updatebuildreferences', 'compute_sha_sums']
}
task makeosX(type: GradleBuild) {
group 'ho'
description 'Create ZipDistribution and MacOS binaries'
tasks = ['init', 'installDist', 'AddResourcesInDistrib', 'ZipDistribution', 'createApp', 'AddResourcesAndZipMacApp']
}
task updatebuildreferences(){
doLast {
if (releaseArtefacts) {
println("artefacts have to be uploaded or it will break update process !!!")
// always update latest.html
new File("$projectDir/docs/latest.html").text = """version=$version
released=${new SimpleDateFormat("dd.MM.yyyy").format(new Date())}
"""
println("latest.html has been updated")
copy {
from "${projectDir}\\src\\main\\resources\\release_notes.md"
into "$projectDir/docs"
rename { filename -> filename.replace('release_notes', 'release_notes(dev)')}
}
println("release notes of DEV version have been updated")
// update latestbeta.html if beta or stable has been released
if (development_stage != '0') {
new File("$projectDir/docs/latestbeta.html").text = """version=$version
released=${new SimpleDateFormat("dd.MM.yyyy").format(new Date())}
"""
println("latestbeta.html has been updated")
copy {
from "${projectDir}\\src\\main\\resources\\release_notes.md"
into "$projectDir/docs"
rename { filename -> filename.replace('release_notes', 'release_notes(beta)')}
}
println("release notes of BETA version have been updated")
}
// update lateststable.html only if stable has been released
if (development_stage == '2') {
new File("$projectDir/docs/lateststable.html").text = """version=$version
released=${new SimpleDateFormat("dd.MM.yyyy").format(new Date())}
"""
println("lateststable.html has been updated")
copy {
from "${projectDir}\\src\\main\\resources\\release_notes.md"
into "$projectDir/docs"
rename { filename -> filename.replace('release_notes', 'release_notes(stable)')}
}
println("release notes of STABLE version have been updated")
}
}
else{
println("html files have not been updated : artefacts should not been released, !!")
}
}
}
task makeWindowsBinarary(type: GradleBuild) {
group 'ho'
description 'Create ZipDistribution and Windows binary'
tasks = ['init', 'installDist', 'AddResourcesInDistrib', 'makeWinInstaller', 'ZipDistribution']
}
task cleanBuild{
doLast {
// Deleting build project ---------------------------------------------------------------------
println("Deleting build project ....")
project.delete(files("${buildDir}/"))
println("Deleting ho build folder ....")
project.delete(files("${projectDir}\\db"))
project.delete(files("${projectDir}\\logs"))
project.delete(files("${projectDir}\\themes"))
project.delete(files("${projectDir}\\user.xml"))
// Creating Target directory ... ---------------------------------------------------------------------
println("creating directory for artefacts: ${target_dir}")
mkdir project.ext.target_dir
}
}
task pushmd {
doLast {
copy {
from "${projectDir}\\src\\main\\resources\\changelog.md"
into "${projectDir}\\docs\\changelog\\md"
}
}
}
task pullhtml {
doLast {
copy {
from "${projectDir}\\docs\\changelog\\html\\changelog.html"
into "${projectDir}\\src\\main\\resources"
}
}
}
task AddResourcesInDistrib {
group 'tool'
dependsOn 'init', 'installDist'
def distribDir = file("${buildDir}/install/XXX")
doLast {
println("adding resources folder")
copy {
from "${projectDir}\\src\\main\\resources\\changelog.html"
into distribDir
}
if (development_stage == '0') {
copy {
from "${projectDir}\\src\\main\\resources\\Logo_dev.ico"
into distribDir
rename "Logo_dev.ico", "Logo.ico"
}
}
else if (development_stage == '1') {
copy {
from "${projectDir}\\src\\main\\resources\\Logo_beta.ico"
into distribDir
rename "Logo_beta.ico", "Logo.ico"
}
}
else {
copy {
from "${projectDir}\\src\\main\\resources\\Logo_stable.ico"
into distribDir
rename "Logo_stable.ico", "Logo.ico"
}
}
copy {
from "${projectDir}\\src\\main\\resources\\prediction"
into "${distribDir}\\prediction"
}
copy {
from "${projectDir}\\src\\main\\resources\\themes"
into "${distribDir}\\themes"
}
copy {
from "${projectDir}\\buildResources\\Win\\HO.bat"
into "${distribDir}"
}
copy {
from "${projectDir}\\buildResources\\Linux\\ho.sh"
into "${distribDir}"
fileMode = 0755
}
copy {
from "${distribDir}/lib"
include "**/*.jar"
into "${distribDir}"
}
delete "${distribDir}\\hamcrest-core-1.3.jar"
delete "${distribDir}\\junit-4.12.jar"
delete "${distribDir}\\bin"
delete "${distribDir}\\lib"
println("renaming distribution")
copy {
from("${distribDir}")
into("${buildDir}/install/${project.version}")
}
delete "${distribDir}"
if (development_stage == '0') {
delete "${buildDir}\\install\\${project.version}\\Logo_beta.ico"
delete "${buildDir}\\install\\${project.version}\\Logo_stable.ico"
delete "${buildDir}\\install\\${project.version}\\ho_logo_beta.png"
delete "${buildDir}\\install\\${project.version}\\ho_logo_stable.png"
}
else if (development_stage == '1') {
delete "${buildDir}\\install\\${project.version}\\Logo_dev.ico"
delete "${buildDir}\\install\\${project.version}\\Logo_stable.ico"
delete "${buildDir}\\install\\${project.version}\\ho_logo_dev.png"
delete "${buildDir}\\install\\${project.version}\\ho_logo_stable.png"
}
else {
delete "${buildDir}\\install\\${project.version}\\Logo_beta.ico"
delete "${buildDir}\\install\\${project.version}\\Logo_dev.ico"
delete "${buildDir}\\install\\${project.version}\\ho_logo_beta.png"
delete "${buildDir}\\install\\${project.version}\\ho_logo_dev.png"
}
}
}
task makeWinInstaller {
description 'Create Win32-Installer using NSIS'
doLast {
println("Creating win32 installer at ${target_dir} using NSIS...")
def DBUILDDIR = "${buildDir}\\install\\${project.version}"
def DOUTFILE="${project.ext.target_dir}\\HO_${project.version}_Win32_Installer.exe"
exec {
executable nsis_exe_path
args "-V2", "-NOCD", "-DBUILDDIR=${DBUILDDIR}", "-DHOVERSION='${project.version}'", "-DCONFPATH=${nsis_confPath}", "-DOUTFILE='${DOUTFILE}'", "${project.ext.nsis_scriptName}"
}
}
}
task finishDeb{
group 'tool'
doLast {
println("copy and rename deb package to artefacts folder")
copy {
from("${buildDir}/distributions")
include("*.deb")
into("${buildDir}/artefacts")
rename { filename -> filename.replace('_all', '').replace('~','-').replace('ho','HO')}
}
}
}
task finishRpm{
group 'tool'
doLast {
println("copy and rename rpm package to artefacts folder")
copy {
from("${buildDir}/distributions")
include("*.rpm")
into("${buildDir}/artefacts")
rename { filename -> filename.replace('.noarch', '').replace('~','-').replace('ho','HO')}
}
}
}
task ZipDistribution(type: Zip) {
println("zipping distribution")
archiveName = "HO_${project.version}.zip"
destinationDir = file("${project.ext.target_dir}")
from ("${buildDir}/install/${project.version}") {exclude("**\\ho.sh", "**\\HO.bat")}
from ("${buildDir}/install/${project.version}") {
include("**\\ho.sh")
fileMode=0755 }
}
task AddResourcesAndZipMacApp {
dependsOn 'init', 'createApp'
def macAppDir = "${buildDir}\\macApp\\HO.app\\Contents\\Java"
doLast {
println("adding resources folder")
copy {
from "${projectDir}\\src\\main\\resources\\changelog.html"
into "${buildDir}\\macApp\\HO.app"
}
delete "${macAppDir}\\hamcrest-core-1.3.jar"
delete "${macAppDir}\\junit-4.12.jar"
println("zipping MacApp distribution")
task(ZipMacAppDistribution, type: Tar) {
archiveName = "HO_${project.version}_macOS.zip"
destinationDir = file("${project.ext.target_dir}")
from ("${buildDir}\\macApp") {exclude("**\\JavaAppLauncher")}
from ("${buildDir}\\macApp") {
include("**\\JavaAppLauncher")
fileMode=0755}
}.execute()
}
}
task createLanguageFileList() {
group 'tool'
def lTranslationFiles = []
fileTree(dir: "${projectDir}\\src\\main\\resources\\sprache", include: '**/*.properties').visit {
FileVisitDetails details -> lTranslationFiles << details.file.name
}
doLast {
println("updating language list filter")
lTranslationFiles = lTranslationFiles.collect { it.take(it.lastIndexOf('.'))}
println lTranslationFiles
File lstFile = new File("${projectDir}\\src\\main\\resources\\sprache\\ListLanguages.txt")
lstFile.withWriter{ out -> lTranslationFiles.each {out.println it}
}
}
}
task compute_sha_sums(){
group 'tool'
description 'compute sha sums of binaries and store them in files'
doLast {
String command = "cmd /c D:\\Anaconda3\\python ${python_script}"
Process p = Runtime.getRuntime().exec(command)
}
}
//apply plugin: 'com.github.breadmoirai.github-release'
//githubRelease {
//
// def _token = GITHUB_TOKEN // required token for your personal access with repo permissions
// owner = 'akasolace'
// repo = 'HO'
//
// println("$target_dir")
// releaseAssets.from("$target_dir")
// println(releaseAssets)
//
// body {
// token = _token
// if (releaseArtefacts) {
// if (development_stage == '0') {
// tagName = "DEV"
// releaseName = "DEV"
// targetCommitish = "master"
// body = "Latest development version (aimed at developers).\nBuild ... Release on ...."
// prerelease = true
// overwrite = false
// println("DEVELOPMENT version has been released on GitHub")
// } else if (development_stage == '1') {
// tagName = "BETA"
// releaseName = "BETA"
// targetCommitish = "master"
// body = "..................."
// prerelease = true
// overwrite = true
// println("BETA version has been released on GitHub.\nBuild ... Release on ....")
// } else if (development_stage == '2') {
// println("automatic release of stable version has not been implemented yet !!")
// }
//
// }
// }}
poeditorPull {
outputs.upToDateWhen { false }
}
poeditor {
apiKey = POEDITOR_APIKEY
projectId = '206221'
trans type:'properties', lang: 'bg', file: 'src\\main\\resources\\sprache\\Bulgarian.properties'
trans type:'properties', lang: 'ca', file: 'src\\main\\resources\\sprache\\Catalan.properties'
trans type:'properties', lang: 'hr', file: 'src\\main\\resources\\sprache\\Hrvatski(Croatian).properties'
trans type:'properties', lang: 'da', file: 'src\\main\\resources\\sprache\\Danish.properties'
trans type:'properties', lang: 'nl', file: 'src\\main\\resources\\sprache\\Nederlands.properties'
trans type:'properties', lang: 'fr', file: 'src\\main\\resources\\sprache\\French.properties'
trans type:'properties', lang: 'de', file: 'src\\main\\resources\\sprache\\Deutsch.properties'
trans type:'properties', lang: 'he', file: 'src\\main\\resources\\sprache\\Hebrew.properties' //Hebrew
trans type:'properties', lang: 'hu', file: 'src\\main\\resources\\sprache\\Magyar.properties' //Hungarian
trans type:'properties', lang: 'it', file: 'src\\main\\resources\\sprache\\Italiano.properties'
trans type:'properties', lang: 'lv', file: 'src\\main\\resources\\sprache\\Latvija.properties' //Lettonie
trans type:'properties', lang: 'pl', file: 'src\\main\\resources\\sprache\\Polish.properties'
trans type:'properties', lang: 'pt-br', file: 'src\\main\\resources\\sprache\\PortuguesBrasil.properties'
trans type:'properties', lang: 'ru', file: 'src\\main\\resources\\sprache\\Russian.properties'
trans type:'properties', lang: 'sr', file: 'src\\main\\resources\\sprache\\Srpski.properties' //Serbian
trans type:'properties', lang: 'sk', file: 'src\\main\\resources\\sprache\\Slovak.properties' //Slovak
trans type:'properties', lang: 'es', file: 'src\\main\\resources\\sprache\\Spanish.properties'
trans type:'properties', lang: 'sv', file: 'src\\main\\resources\\sprache\\Svenska.properties' //Swedish
trans type:'properties', lang: 'tr', file: 'src\\main\\resources\\sprache\\Turkish.properties'
}
markdownToHtml {
sourceDir = new File("${projectDir}\\docs\\changelog\\md")
outputDir = new File("${projectDir}\\docs\\changelog\\html")
markdownToHtml.hardwraps = true
}
//// task ReleaseToGitHub is broken until upstream fix ===================================
// apply plugin: 'com.github.breadmoirai.github-release'
// githubRelease {
// def _token = GITHUB_TOKEN // required token for your personal access with repo permissions
// owner = 'akasolace'
// repo = 'HO'
// println(file("$target_dir"))
// releaseAssets = file("$target_dir").listFiles()
// println(releaseAssets)
//
// token = _token
// if (releaseArtefacts) {
// if (development_stage == '0') {
// tagName = "dev"
// releaseName = "dev"
// targetCommitish = "master"
// body = "Latest development version (aimed at developers).\nBuild ... Release on ...."
// prerelease = true
// overwrite = true
// println("DEVELOPMENT version has been released on GitHub")
// } else if (development_stage == '1') {
// tagName = "BETA"
// releaseName = "BETA"
// targetCommitish = "master"
// body = "..................."
// prerelease = true
// overwrite = true
// println("BETA version has been released on GitHub.\nBuild ... Release on ....")
// } else if (development_stage == '2') {
// println("automatic release of stable version has not been implemented yet !!")
// }
//
// }
//
//
//
// }