Skip to content

Commit

Permalink
Merge pull request #317 from codeconsole/gradle-89-compat
Browse files Browse the repository at this point in the history
Gradle 8.10 compatibility
  • Loading branch information
codeconsole authored Aug 16, 2024
2 parents f1623f5 + a7cc754 commit e56b270
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 89 deletions.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,13 @@ import groovy.transform.CompileDynamic
import groovy.transform.CompileStatic
import org.gradle.api.Action
import org.gradle.api.file.FileTree
import org.gradle.api.model.ObjectFactory
import org.gradle.api.tasks.*
import org.gradle.api.tasks.compile.AbstractCompile
import org.gradle.process.ExecResult
import org.gradle.process.JavaExecSpec

import javax.inject.Inject
import java.nio.file.Files
import java.nio.file.Path
import java.nio.file.Paths
Expand All @@ -22,7 +24,7 @@ import java.nio.file.Paths
* @since 4.0
*/
@CompileStatic
class GroovyPageForkCompileTask extends AbstractCompile {
abstract class GroovyPageForkCompileTask extends AbstractCompile {

@Input
@Optional
Expand All @@ -46,8 +48,13 @@ class GroovyPageForkCompileTask extends AbstractCompile {
@Optional
String serverpath

@Inject
protected ObjectFactory getObjectFactory() {
throw new UnsupportedOperationException();
}

@Nested
GspCompileOptions compileOptions = new GspCompileOptions()
GspCompileOptions compileOptions = getObjectFactory().newInstance(GspCompileOptions.class)

@Override
@PathSensitive(PathSensitivity.RELATIVE)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,22 +1,29 @@
package org.grails.gradle.plugin.web.gsp

import org.gradle.api.model.ObjectFactory
import org.gradle.api.tasks.Input
import org.gradle.api.tasks.Nested
import org.gradle.api.tasks.compile.BaseForkOptions
import org.gradle.api.tasks.compile.AbstractOptions
import org.gradle.api.tasks.compile.GroovyForkOptions
import javax.inject.Inject;

/**
* Presents the Compile Options used by the {@llink GroovyPageForkCompileTask}
*
* @author David Estes
* @since 4.0
*/
class GspCompileOptions implements Serializable {
* Presents the Compile Options used by the {@llink GroovyPageForkCompileTask}
*
* @author David Estes
* @since 4.0
*/
abstract class GspCompileOptions extends AbstractOptions {
private static final long serialVersionUID = 0L;

@Input
String encoding = "UTF-8"
String encoding = "UTF-8"

@Inject
protected ObjectFactory getObjectFactory() {
throw new UnsupportedOperationException();
}

@Nested
GroovyForkOptions forkOptions = new GroovyForkOptions()
GroovyForkOptions forkOptions = getObjectFactory().newInstance(GroovyForkOptions.class)
}

0 comments on commit e56b270

Please sign in to comment.