Skip to content

Commit

Permalink
Merge branch '7.0.x' into renovate/major-apache-maven-resolver-monorepo
Browse files Browse the repository at this point in the history
  • Loading branch information
jamesfredley authored Oct 24, 2024
2 parents 01a052d + 5cdcb08 commit 59d743e
Show file tree
Hide file tree
Showing 9 changed files with 49 additions and 36 deletions.
6 changes: 5 additions & 1 deletion .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,11 @@ jobs:
steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: "☕️ Setup JDK"
uses: actions/setup-java@v4
with:
distribution: liberica
java-version: 17
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v3
Expand Down
9 changes: 5 additions & 4 deletions .github/workflows/gradle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,17 +13,18 @@ jobs:
build:
permissions:
contents: read # to fetch code (actions/checkout)
runs-on: ubuntu-latest
strategy:
matrix:
java: [17]
java: [17, 21, 23]
os: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.os }}
steps:
- name: "📥 Checkout repository"
uses: actions/checkout@v4
- name: "☕️ Setup JDK"
uses: actions/setup-java@v4
with:
distribution: temurin
distribution: liberica
java-version: ${{ matrix.java }}
- name: "🐘 Setup Gradle"
uses: gradle/actions/setup-gradle@v4
Expand All @@ -47,7 +48,7 @@ jobs:
- name: "☕️ Setup JDK"
uses: actions/setup-java@v4
with:
distribution: temurin
distribution: liberica
java-version: 17
- name: "🐘 Setup Gradle"
uses: gradle/actions/setup-gradle@v4
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/groovy-joint-workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
- name: "☕️ Setup JDK"
uses: actions/setup-java@v4
with:
distribution: temurin
distribution: liberica
java-version: 17
- name: "🗄️ Cache local Maven repository"
uses: actions/cache@v4
Expand Down Expand Up @@ -121,7 +121,7 @@ jobs:
- name: "☕️ Setup JDK"
uses: actions/setup-java@v4
with:
distribution: temurin
distribution: liberica
java-version: 17
- name: "🐘 Setup Gradle"
uses: gradle/actions/setup-gradle@v4
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
- name: "☕️ Setup JDK"
uses: actions/setup-java@v4
with:
distribution: temurin
distribution: liberica
java-version: 17
- name: "🐘 Setup Gradle"
uses: gradle/actions/setup-gradle@v4
Expand Down Expand Up @@ -97,7 +97,7 @@ jobs:
- name: "☕️ Setup JDK"
uses: actions/setup-java@v4
with:
distribution: temurin
distribution: liberica
java-version: 17
- name: "🐘 Setup Gradle"
uses: gradle/actions/setup-gradle@v4
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/retry-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ jobs:
- name: "☕️ Setup JDK"
uses: actions/setup-java@387ac29b308b003ca37ba93a6cab5eb57c8f5f93 # v4
with:
distribution: temurin
distribution: liberica
java-version: 17
- name: "🐘 Setup Gradle"
uses: gradle/actions/setup-gradle@v4
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/sdkman.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ jobs:
- name: "☕️ Setup JDK"
uses: actions/setup-java@v4
with:
distribution: temurin
distribution: liberica
java-version: 17
- name: "🐘 Setup Gradle"
uses: gradle/actions/setup-gradle@v4
Expand Down
33 changes: 19 additions & 14 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -172,8 +172,6 @@ subprojects { subproject ->
version = grailsVersion
group = "org.grails"

if (subproject.name == 'grails-bom') return

ext.isTestSuite = subproject.name.startsWith("grails-test-suite")
ext.isCiBuild = subproject.hasProperty("isCiBuild") || System.getenv().get("CI") as Boolean
ext.pomInfo = {
Expand Down Expand Up @@ -205,20 +203,24 @@ subprojects { subproject ->

}

apply plugin: 'java-library'
apply plugin: 'groovy'
apply plugin: 'eclipse'
apply plugin: 'idea'
apply plugin: 'project-report'
if (subproject.name != 'grails-bom') {
apply plugin: 'java-library'
apply plugin: 'groovy'
apply plugin: 'eclipse'
apply plugin: 'idea'
apply plugin: 'project-report'
}

if (!isTestSuite) {

apply plugin: 'maven-publish'
apply plugin: 'signing'

java {
withJavadocJar()
withSourcesJar()
if (subproject.name != 'grails-bom') {
java {
withJavadocJar()
withSourcesJar()
}
}
publishing {

Expand Down Expand Up @@ -267,8 +269,9 @@ subprojects { subproject ->
}
}
}

from components.java
if (subproject.name != 'grails-bom') {
from components.java
}
}
}
}
Expand All @@ -290,7 +293,7 @@ subprojects { subproject ->
}
}

if (subproject.name == 'grails-dependencies') return
if (subproject.name in ['grails-dependencies', 'grails-bom']) return

dependencies {
implementation platform(project(':grails-bom'))
Expand Down Expand Up @@ -461,7 +464,9 @@ subprojects { subproject ->
}
}

java.toolchain.languageVersion = JavaLanguageVersion.of(17)
compileJava {
options.release = 17
}

if (!isTestSuite) {
tasks.register('installToHomeDist', Copy) {
Expand Down
4 changes: 2 additions & 2 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ org.gradle.parallel=true
org.gradle.daemon=true
org.gradle.jvmargs=-Dfile.encoding=UTF-8 -Xmx1536M -XX:MaxMetaspaceSize=1024M

# Generated on Mon Oct 21 14:36:55 PDT 2024 by: ./gradlew :grails-bom:syncProps
# Generated on Tue Oct 22 16:16:30 EDT 2024 by: ./gradlew :grails-bom:syncProps
# Only version value modifications allowed after this point. Do not insert or change version names.
ant.version=1.10.15
asciidoctorj.version=3.0.0
Expand All @@ -43,7 +43,7 @@ groovy.version=4.0.23
gsp.version=7.0.0-SNAPSHOT
h2.version=2.3.232
jackson.version=2.18.0
jansi.version=2.4.1
jansi.version=1.18
javaparser-core.version=3.26.2
jline.version=2.14.6
jna.version=5.15.0
Expand Down
21 changes: 12 additions & 9 deletions grails-bom/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

plugins {
id 'java-platform'
id 'maven-publish'
}

javaPlatform {
Expand Down Expand Up @@ -154,20 +153,23 @@ publishing {
}

task syncProps {
def gradlePropertiesFile = rootProject.layout.projectDirectory.file('gradle.properties').asFile
String oldProperties = gradlePropertiesFile.text
gradlePropertiesFile.write(oldProperties.substring(0, oldProperties.indexOf("# Generated on")) + """\
doLast {
def gradlePropertiesFile = rootProject.layout.projectDirectory.file('gradle.properties').asFile
String oldProperties = gradlePropertiesFile.text
gradlePropertiesFile.write(oldProperties.substring(0, oldProperties.indexOf("# Generated on")) + """\
# Generated on ${new Date()} by: ./gradlew :grails-bom:${name}
# Only version value modifications allowed after this point. Do not insert or change version names.
${dependenciesVersions.collect { "$it.version=$it.versionValue" }.join('\n ')}
""".stripIndent(true).trim())
println "${gradlePropertiesFile} updated."
println "${gradlePropertiesFile} updated."
}
}

task dependabotBuild {
def dependabotBuildFile = rootProject.layout.projectDirectory.file('dependabot/build.gradle').asFile
dependabotBuildFile.parentFile.mkdirs()
dependabotBuildFile.write("""\
doLast {
def dependabotBuildFile = rootProject.layout.projectDirectory.file('dependabot/build.gradle').asFile
dependabotBuildFile.parentFile.mkdirs()
dependabotBuildFile.write("""\
// Generated on ${new Date()} by: ./gradlew :grails-bom:${name}
plugins {
id 'java-library'
Expand All @@ -177,7 +179,8 @@ task dependabotBuild {
${allDependencies.collect { " api \"${it.groupId}:${it.artifactId}:\${project['${it.version}']}\"" }.join('\n ')}
}
""".stripIndent(true).trim())
println "${dependabotBuildFile} created."
println "${dependabotBuildFile} created."
}
}

task dependabot {
Expand Down

0 comments on commit 59d743e

Please sign in to comment.