Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion documentation/documentation.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,9 @@ dependencies {
reportAggregation project(':hibernate-processor')
reportAggregation project(':hibernate-community-dialects')

dialectReportSources project( ':hibernate-core' )
communityDialectReportSources project( ':hibernate-community-dialects' )

core project( ':hibernate-core' )
javadocSources project( path: ':hibernate-core', configuration: 'javadocSources' )

Expand Down Expand Up @@ -226,7 +229,7 @@ def aggregateJavadocsTask = tasks.register( "javadoc", Javadoc ) {
asciidoctorj {
requires 'rouge'
// Set version of AsciidoctorJ (plugin is currently uses 2.5.7 ? by default)
version '3.0.0'
version = '3.0.0'
modules {
pdf {
version '2.3.18'
Expand Down
7 changes: 6 additions & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,9 @@ org.gradle.java.installations.auto-download=false
orm.jdk.base=17
orm.jdk.min=21
# See gradlew/wrapper/gradle-wrapper.properties, https://docs.gradle.org/current/userguide/compatibility.html#java_runtime
orm.jdk.max=22
orm.jdk.max=22

# The minimum version of Gradle supported for the ORM Gradle plugin.
# This is the version used in the plugin tests, used to make sure we do not break compatibility.
# See `org.hibernate.orm.tooling.gradle.TestHelper`
orm.gradle.min=8.14
Binary file modified gradle/wrapper/gradle-wrapper.jar
Binary file not shown.
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-8.14.3-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-9.1.0-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
Expand Down
14 changes: 8 additions & 6 deletions gradlew
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
#!/bin/sh

#
# Copyright © 2015-2021 the original authors.
# Copyright © 2015 the original authors.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
Expand All @@ -15,6 +15,8 @@
# See the License for the specific language governing permissions and
# limitations under the License.
#
# SPDX-License-Identifier: Apache-2.0
#

##############################################################################
#
Expand Down Expand Up @@ -55,7 +57,7 @@
# Darwin, MinGW, and NonStop.
#
# (3) This script is generated from the Groovy template
# https://github.com/gradle/gradle/blob/HEAD/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
# https://github.com/gradle/gradle/blob/HEAD/platforms/jvm/plugins-application/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt
# within the Gradle project.
#
# You can find Gradle at https://github.com/gradle/gradle/.
Expand Down Expand Up @@ -84,7 +86,7 @@ done
# shellcheck disable=SC2034
APP_BASE_NAME=${0##*/}
# Discard cd standard output in case $CDPATH is set (https://github.com/gradle/gradle/issues/25036)
APP_HOME=$( cd "${APP_HOME:-./}" > /dev/null && pwd -P ) || exit
APP_HOME=$( cd -P "${APP_HOME:-./}" > /dev/null && printf '%s\n' "$PWD" ) || exit

# Use the maximum available, or set MAX_FD != -1 to use that value.
MAX_FD=maximum
Expand Down Expand Up @@ -112,7 +114,7 @@ case "$( uname )" in #(
NONSTOP* ) nonstop=true ;;
esac

CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
CLASSPATH="\\\"\\\""


# Determine the Java command to use to start the JVM.
Expand Down Expand Up @@ -203,15 +205,15 @@ fi
DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"'

# Collect all arguments for the java command:
# * DEFAULT_JVM_OPTS, JAVA_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments,
# * DEFAULT_JVM_OPTS, JAVA_OPTS, and optsEnvironmentVar are not allowed to contain shell fragments,
# and any embedded shellness will be escaped.
# * For example: A user cannot expect ${Hostname} to be expanded, as it is an environment variable and will be
# treated as '${Hostname}' itself on the command line.

set -- \
"-Dorg.gradle.appname=$APP_BASE_NAME" \
-classpath "$CLASSPATH" \
org.gradle.wrapper.GradleWrapperMain \
-jar "$APP_HOME/gradle/wrapper/gradle-wrapper.jar" \
"$@"

# Stop when "xargs" is not available.
Expand Down
26 changes: 14 additions & 12 deletions gradlew.bat
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
@rem See the License for the specific language governing permissions and
@rem limitations under the License.
@rem
@rem SPDX-License-Identifier: Apache-2.0
@rem

@if "%DEBUG%"=="" @echo off
@rem ##########################################################################
Expand Down Expand Up @@ -43,11 +45,11 @@ set JAVA_EXE=java.exe
%JAVA_EXE% -version >NUL 2>&1
if %ERRORLEVEL% equ 0 goto execute

echo.
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
echo.
echo Please set the JAVA_HOME variable in your environment to match the
echo location of your Java installation.
echo. 1>&2
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 1>&2
echo. 1>&2
echo Please set the JAVA_HOME variable in your environment to match the 1>&2
echo location of your Java installation. 1>&2

goto fail

Expand All @@ -57,22 +59,22 @@ set JAVA_EXE=%JAVA_HOME%/bin/java.exe

if exist "%JAVA_EXE%" goto execute

echo.
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
echo.
echo Please set the JAVA_HOME variable in your environment to match the
echo location of your Java installation.
echo. 1>&2
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 1>&2
echo. 1>&2
echo Please set the JAVA_HOME variable in your environment to match the 1>&2
echo location of your Java installation. 1>&2

goto fail

:execute
@rem Setup the command line

set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
set CLASSPATH=


@rem Execute Gradle
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %*
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" -jar "%APP_HOME%\gradle\wrapper\gradle-wrapper.jar" %*

:end
@rem End local scope for the variables with windows NT shell
Expand Down
2 changes: 1 addition & 1 deletion local-build-plugins/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ gradlePlugin {

spotless {
//Don't fail during the check: rather than enforcing guidelines, we use this plugin to fix mistakes automatically.
enforceCheck false
enforceCheck = false
java {
targetExclude( "**/target/**/*.java" )
licenseHeaderFile project.file("../shared/config/spotless/license.java")
Expand Down
12 changes: 6 additions & 6 deletions local-build-plugins/src/main/groovy/local.code-quality.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,8 @@ plugins {

tasks.register( "ciCheck" ) {
// Task used by CI builds
group "verification"
description "Checks for CI environments"
group = "verification"
description = "Checks for CI environments"
dependsOn tasks.check
}

Expand All @@ -27,8 +27,8 @@ gradle.taskGraph.whenReady {

tasks.register( "formatChecks" ) {
// Only runs static code analysis, doesn't require compilation
group "verification"
description "Code style and formatting checks"
group = "verification"
description = "Code style and formatting checks"

dependsOn tasks.spotlessCheck
dependsOn tasks.enforceRules
Expand Down Expand Up @@ -92,10 +92,10 @@ tasks.check.dependsOn enforceRulesTask

spotless {
//Don't fail during the check: rather than enforcing guidelines, we use this plugin to fix mistakes automatically.
enforceCheck false
enforceCheck = false
java {
targetExclude( "target/**/*.java" )
licenseHeaderFile rootProject.file("shared/config/spotless/license.java")
licenseHeaderFile( rootProject.file("shared/config/spotless/license.java") )
removeUnusedImports()
leadingSpacesToTabs( 4 )
trimTrailingWhitespace()
Expand Down
4 changes: 2 additions & 2 deletions local-build-plugins/src/main/groovy/local.java-module.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ tasks.register('compile') {

tasks.withType( JavaCompile ).configureEach {
options.encoding = 'UTF-8'
options.warnings false
options.warnings = false
options.fork = true
options.forkOptions.memoryMaximumSize = '896m'

Expand All @@ -162,7 +162,7 @@ tasks.withType( JavaCompile ).configureEach {
}

processTestResources {
duplicatesStrategy DuplicatesStrategy.INCLUDE
duplicatesStrategy = DuplicatesStrategy.INCLUDE

inputs.property( "db", db )
inputs.property( "dbHost", dbHost )
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ publishingExtension.publications.named("publishedArtifacts", MavenPublication) {
// Releasing

def releasePrepareTask = tasks.register("releasePrepare") {
group "release"
description "See :release:releasePrepare for details. Here we hook in testing and checks ensure publish-ability"
group = "release"
description = "See :release:releasePrepare for details. Here we hook in testing and checks ensure publish-ability"

dependsOn tasks.check
dependsOn tasks.generateMetadataFileForPublishedArtifactsPublication
Expand All @@ -56,8 +56,8 @@ def releasePrepareTask = tasks.register("releasePrepare") {

// used from the h2 CI job
tasks.register("preVerifyRelease") {
group "release-prepare"
description "Delegates to `releasePrepare` task"
group = "release-prepare"
description = "Delegates to `releasePrepare` task"

dependsOn releasePrepareTask
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
import org.gradle.api.tasks.PathSensitive;
import org.gradle.api.tasks.PathSensitivity;
import org.gradle.api.tasks.TaskAction;
import org.gradle.process.ExecOperations;

import static org.hibernate.orm.antlr.AntlrHelper.stripSillyGeneratedFromLines;

Expand All @@ -27,6 +28,7 @@
@CacheableTask
public abstract class SplitGrammarGenerationTask extends DefaultTask {
private final SplitGrammarDescriptor grammarDescriptor;
private final ExecOperations execOperations;

private final Provider<RegularFile> lexerGrammarFile;
private final Provider<RegularFile> parserGrammarFile;
Expand All @@ -35,8 +37,12 @@ public abstract class SplitGrammarGenerationTask extends DefaultTask {
private final Provider<Directory> outputDirectory;

@Inject
public SplitGrammarGenerationTask(SplitGrammarDescriptor grammarDescriptor, AntlrSpec antlrSpec) {
public SplitGrammarGenerationTask(
SplitGrammarDescriptor grammarDescriptor,
AntlrSpec antlrSpec,
ExecOperations execOperations) {
this.grammarDescriptor = grammarDescriptor;
this.execOperations = execOperations;

lexerGrammarFile = getProject().provider( () -> {
final Directory grammarBaseDirectory = antlrSpec.getGrammarBaseDirectory().get();
Expand Down Expand Up @@ -109,9 +115,9 @@ private void generateLexer(File outputDir) {
);


getProject().javaexec(
execOperations.javaexec(
(javaExecSpec) -> {
javaExecSpec.setMain( "org.antlr.v4.Tool" );
javaExecSpec.getMainClass().set( "org.antlr.v4.Tool" );
javaExecSpec.classpath( getProject().getConfigurations().getByName( "antlr" ) );
javaExecSpec.args(
"-o", getProject().relativePath( outputDir.getAbsolutePath() ),
Expand All @@ -133,9 +139,9 @@ private void generateParser(File outputDir) {
);


getProject().javaexec(
execOperations.javaexec(
(javaExecSpec) -> {
javaExecSpec.setMain( "org.antlr.v4.Tool" );
javaExecSpec.getMainClass().set( "org.antlr.v4.Tool" );
javaExecSpec.classpath( getProject().getConfigurations().named( "antlr" ) );
javaExecSpec.args(
"-o", getProject().relativePath( outputDir.getAbsolutePath() ),
Expand Down

This file was deleted.

Loading