Skip to content

Commit

Permalink
minor refactor: use later gradle syntax
Browse files Browse the repository at this point in the history
  • Loading branch information
paulk-asert committed Jan 6, 2025
1 parent a6ed882 commit 3c6596c
Showing 1 changed file with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ import org.gradle.api.DefaultTask
import org.gradle.api.file.ConfigurableFileCollection
import org.gradle.api.file.ConfigurableFileTree
import org.gradle.api.file.DirectoryProperty
import org.gradle.api.model.ObjectFactory
import org.gradle.api.tasks.CacheableTask
import org.gradle.api.tasks.Classpath
import org.gradle.api.tasks.InputFiles
Expand All @@ -41,7 +42,6 @@ class DgmConverter extends DefaultTask {

private final ExecOperations execOperations


@OutputDirectory
final DirectoryProperty outputDirectory

Expand All @@ -54,12 +54,12 @@ class DgmConverter extends DefaultTask {
final ConfigurableFileCollection classpath

@Inject
DgmConverter(ExecOperations execOperations) {
DgmConverter(ExecOperations execOperations, ObjectFactory objects) {
description = 'Generates DGM info file required for faster startup.'
this.execOperations = execOperations
classpath = project.objects.fileCollection()
sources = project.objects.fileTree()
outputDirectory = project.objects.directoryProperty().convention(
classpath = objects.fileCollection()
sources = objects.fileTree()
outputDirectory = objects.directoryProperty().convention(
project.layout.buildDirectory.dir("dgm")
)
}
Expand Down

0 comments on commit 3c6596c

Please sign in to comment.