Skip to content

Commit

Permalink
Ignore empty directories for sources
Browse files Browse the repository at this point in the history
Empty directories should not matter for source files, so let's ignore
them for up-to-date checks as well.
  • Loading branch information
wolfs committed Nov 3, 2021
1 parent 1435707 commit 82400ab
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@
*/
package com.google.protobuf.gradle

import org.gradle.api.tasks.IgnoreEmptyDirectories

import static java.nio.charset.StandardCharsets.US_ASCII

import com.google.common.base.Preconditions
Expand Down Expand Up @@ -302,8 +304,9 @@ public abstract class GenerateProtoTask extends DefaultTask {
}

@SkipWhenEmpty
@InputFiles
@PathSensitive(PathSensitivity.RELATIVE)
@IgnoreEmptyDirectories
@InputFiles
FileCollection getSourceFiles() {
return sourceFiles
}
Expand Down

0 comments on commit 82400ab

Please sign in to comment.