Skip to content

Commit dd53c4b

Browse files
committed
Implement task inputs matching the Spring Boot task inputs
1 parent 9e726b3 commit dd53c4b

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/main/kotlin/org/springdoc/openapi/gradle/plugin/OpenApiGradlePlugin.kt

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,10 +59,13 @@ open class OpenApiGradlePlugin : Plugin<Project> {
5959
fork.onlyIf { needToFork(bootRunTask, customBootRun, fork) }
6060
}
6161

62-
// This is my task. Before I can run it, I have to run the dependent tasks
6362
val openApiTask =
6463
tasks.named(OPEN_API_TASK_NAME, OpenApiGeneratorTask::class.java) {
64+
// This is my task. Before I can run it, I have to run the dependent tasks
6565
it.dependsOn(forkedSpringBoot)
66+
67+
// Ensure the task inputs match those of the original application
68+
it.inputs.files(bootRunTask.get().inputs.files)
6669
}
6770

6871
// The forked task need to be terminated as soon as my task is finished

0 commit comments

Comments
 (0)