From 7c6c7b739e8ded7c0cd04ad2ffc06ab25bda6ca0 Mon Sep 17 00:00:00 2001 From: buervenich_g Date: Thu, 16 Sep 2021 12:54:56 +0200 Subject: [PATCH] Change annotation on property `classBaseDirectory` to comply with Gradle 7. Fixes #143 Annotation `@Input` is no longer allowed on properties of type `File`. Instead, a new method is added that returns the directory path as a String and is annotated with `@Input`. This ensures that up-to-date checks consider the path (but not its content) of the property, as was the behaviour before. The existing method is instead annotated as `@Internal`. --- .../java/com/fizzed/rocker/gradle/RockerConfiguration.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/rocker-gradle-plugin/src/main/java/com/fizzed/rocker/gradle/RockerConfiguration.java b/rocker-gradle-plugin/src/main/java/com/fizzed/rocker/gradle/RockerConfiguration.java index d54735a..350fdc3 100644 --- a/rocker-gradle-plugin/src/main/java/com/fizzed/rocker/gradle/RockerConfiguration.java +++ b/rocker-gradle-plugin/src/main/java/com/fizzed/rocker/gradle/RockerConfiguration.java @@ -156,6 +156,11 @@ public void setOutputBaseDirectory(Object outputBaseDirectory, PathValidation pv } @Input // Neither input nor output directory, but generated rocker.conf depends on it + public String getClassBaseDirectoryPath() { + return classBaseDirectory.getAbsolutePath(); + } + + @Internal public File getClassBaseDirectory() { return classBaseDirectory; }