diff --git a/src/main/groovy/com/netflix/gradle/plugins/deb/Deb.groovy b/src/main/groovy/com/netflix/gradle/plugins/deb/Deb.groovy index 2d329df1..ab56454a 100755 --- a/src/main/groovy/com/netflix/gradle/plugins/deb/Deb.groovy +++ b/src/main/groovy/com/netflix/gradle/plugins/deb/Deb.groovy @@ -21,10 +21,12 @@ import com.netflix.gradle.plugins.packaging.Dependency import com.netflix.gradle.plugins.packaging.SystemPackagingTask import org.gradle.api.internal.ConventionMapping import org.gradle.api.internal.IConventionAware +import org.gradle.api.tasks.CacheableTask import org.gradle.api.tasks.Input import org.gradle.api.tasks.Optional import org.gradle.api.tasks.OutputFile +@CacheableTask class Deb extends SystemPackagingTask { Deb() { super() diff --git a/src/main/groovy/com/netflix/gradle/plugins/packaging/SystemPackagingExtension.groovy b/src/main/groovy/com/netflix/gradle/plugins/packaging/SystemPackagingExtension.groovy index 79eb8883..2456bdc3 100755 --- a/src/main/groovy/com/netflix/gradle/plugins/packaging/SystemPackagingExtension.groovy +++ b/src/main/groovy/com/netflix/gradle/plugins/packaging/SystemPackagingExtension.groovy @@ -4,6 +4,8 @@ import com.netflix.gradle.plugins.deb.control.MultiArch import org.gradle.api.tasks.Input import org.gradle.api.tasks.InputFile import org.gradle.api.tasks.Optional +import org.gradle.api.tasks.PathSensitive +import org.gradle.api.tasks.PathSensitivity import org.redline_rpm.header.Architecture import org.redline_rpm.header.Os import org.redline_rpm.header.RpmType @@ -47,7 +49,7 @@ class SystemPackagingExtension { @Input @Optional String signingKeyPassphrase - @InputFile @Optional + @InputFile @Optional @PathSensitive(PathSensitivity.RELATIVE) File signingKeyRingFile // Metadata, some are probably specific to a type @@ -158,13 +160,13 @@ class SystemPackagingExtension { // Scripts - @InputFile @Optional + @InputFile @Optional @PathSensitive(PathSensitivity.RELATIVE) File preInstallFile - @InputFile @Optional + @InputFile @Optional @PathSensitive(PathSensitivity.RELATIVE) File postInstallFile - @InputFile @Optional + @InputFile @Optional @PathSensitive(PathSensitivity.RELATIVE) File preUninstallFile - @InputFile @Optional + @InputFile @Optional @PathSensitive(PathSensitivity.RELATIVE) File postUninstallFile final List configurationFiles = [] diff --git a/src/main/groovy/com/netflix/gradle/plugins/packaging/SystemPackagingTask.groovy b/src/main/groovy/com/netflix/gradle/plugins/packaging/SystemPackagingTask.groovy index df4f4191..826b17af 100755 --- a/src/main/groovy/com/netflix/gradle/plugins/packaging/SystemPackagingTask.groovy +++ b/src/main/groovy/com/netflix/gradle/plugins/packaging/SystemPackagingTask.groovy @@ -284,6 +284,7 @@ abstract class SystemPackagingTask extends AbstractArchiveTask { * @return Collection of files */ @InputFiles + @PathSensitive(PathSensitivity.RELATIVE) @SkipWhenEmpty private final FileCollection getFakeFiles() { project.files('fake') diff --git a/src/main/groovy/com/netflix/gradle/plugins/rpm/Rpm.groovy b/src/main/groovy/com/netflix/gradle/plugins/rpm/Rpm.groovy index 99f08dd8..79c0ba9f 100755 --- a/src/main/groovy/com/netflix/gradle/plugins/rpm/Rpm.groovy +++ b/src/main/groovy/com/netflix/gradle/plugins/rpm/Rpm.groovy @@ -18,17 +18,20 @@ package com.netflix.gradle.plugins.rpm import com.netflix.gradle.plugins.packaging.AbstractPackagingCopyAction import com.netflix.gradle.plugins.packaging.SystemPackagingTask -import org.gradle.api.tasks.Input -import org.gradle.api.tasks.InputFile; +import org.gradle.api.tasks.CacheableTask +import org.gradle.api.tasks.InputFile import org.gradle.api.tasks.Optional +import org.gradle.api.tasks.PathSensitive +import org.gradle.api.tasks.PathSensitivity import org.redline_rpm.header.Architecture import org.redline_rpm.header.Os import org.redline_rpm.header.RpmType import org.gradle.api.internal.ConventionMapping import org.gradle.api.internal.IConventionAware +@CacheableTask class Rpm extends SystemPackagingTask { - @InputFile @Optional + @InputFile @Optional @PathSensitive(PathSensitivity.RELATIVE) File changeLogFile Rpm() {