build.gradle 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120
  1. plugins {
  2. id "java-gradle-plugin"
  3. id "java"
  4. id "groovy"
  5. id 'com.apollographql.apollo' version '2.4.5'
  6. }
  7. sourceCompatibility = JavaVersion.VERSION_17
  8. repositories {
  9. gradlePluginPortal()
  10. mavenCentral()
  11. }
  12. sourceSets {
  13. main {
  14. java {
  15. srcDirs = []
  16. }
  17. groovy {
  18. srcDirs += ["src/main/java"]
  19. }
  20. }
  21. }
  22. gradlePlugin {
  23. plugins {
  24. checkAntoraVersion {
  25. id = "org.springframework.antora.check-version"
  26. implementationClass = "org.springframework.gradle.antora.AntoraVersionPlugin"
  27. }
  28. trang {
  29. id = "trang"
  30. implementationClass = "trang.TrangPlugin"
  31. }
  32. locks {
  33. id = "locks"
  34. implementationClass = "lock.GlobalLockPlugin"
  35. }
  36. managementConfiguration {
  37. id = "io.spring.convention.management-configuration"
  38. implementationClass = "io.spring.gradle.convention.ManagementConfigurationPlugin"
  39. }
  40. updateDependencies {
  41. id = "org.springframework.security.update-dependencies"
  42. implementationClass = "org.springframework.security.convention.versions.UpdateDependenciesPlugin"
  43. }
  44. updateProjectVersion {
  45. id = "org.springframework.security.update-version"
  46. implementationClass = "org.springframework.security.convention.versions.UpdateProjectVersionPlugin"
  47. }
  48. sagan {
  49. id = "org.springframework.security.sagan"
  50. implementationClass = "org.springframework.gradle.sagan.SaganPlugin"
  51. }
  52. githubMilestone {
  53. id = "org.springframework.github.milestone"
  54. implementationClass = "org.springframework.gradle.github.milestones.GitHubMilestonePlugin"
  55. }
  56. githubChangelog {
  57. id = "org.springframework.github.changelog"
  58. implementationClass = "org.springframework.gradle.github.changelog.GitHubChangelogPlugin"
  59. }
  60. githubRelease {
  61. id = "org.springframework.github.release"
  62. implementationClass = "org.springframework.gradle.github.release.GitHubReleasePlugin"
  63. }
  64. s101 {
  65. id = "s101"
  66. implementationClass = "s101.S101Plugin"
  67. }
  68. }
  69. }
  70. configurations {
  71. implementation {
  72. exclude module: 'groovy-all'
  73. }
  74. }
  75. dependencies {
  76. implementation 'com.google.code.gson:gson:2.8.6'
  77. implementation 'com.thaiopensource:trang:20091111'
  78. implementation 'net.sourceforge.saxon:saxon:9.1.0.8'
  79. implementation 'org.yaml:snakeyaml:1.30'
  80. implementation localGroovy()
  81. implementation 'io.github.gradle-nexus:publish-plugin:1.1.0'
  82. implementation 'io.projectreactor:reactor-core:3.5.5'
  83. implementation 'org.gretty:gretty:3.0.9'
  84. implementation 'com.apollographql.apollo:apollo-runtime:2.4.5'
  85. implementation 'com.github.ben-manes:gradle-versions-plugin:0.38.0'
  86. implementation 'com.github.spullara.mustache.java:compiler:0.9.4'
  87. implementation 'io.spring.javaformat:spring-javaformat-gradle-plugin:0.0.15'
  88. implementation 'io.spring.nohttp:nohttp-gradle:0.0.11'
  89. implementation 'net.sourceforge.htmlunit:htmlunit:2.37.0'
  90. implementation 'org.hidetake:gradle-ssh-plugin:2.10.1'
  91. implementation 'org.jfrog.buildinfo:build-info-extractor-gradle:4.29.0'
  92. implementation 'org.sonarsource.scanner.gradle:sonarqube-gradle-plugin:2.7.1'
  93. testImplementation platform('org.junit:junit-bom:5.9.2')
  94. testImplementation "org.junit.jupiter:junit-jupiter-api"
  95. testImplementation "org.junit.jupiter:junit-jupiter-params"
  96. testImplementation "org.junit.jupiter:junit-jupiter-engine"
  97. testImplementation 'org.apache.commons:commons-io:1.3.2'
  98. testImplementation 'org.assertj:assertj-core:3.13.2'
  99. testImplementation 'org.mockito:mockito-core:3.12.4'
  100. testImplementation 'org.mockito:mockito-junit-jupiter:3.12.4'
  101. testImplementation "com.squareup.okhttp3:mockwebserver:3.14.9"
  102. }
  103. tasks.named('test', Test).configure {
  104. onlyIf { !project.hasProperty("buildSrc.skipTests") }
  105. useJUnitPlatform()
  106. jvmArgs(
  107. '--add-opens', 'java.base/java.lang=ALL-UNNAMED',
  108. '--add-opens', 'java.base/java.util=ALL-UNNAMED'
  109. )
  110. }