springdoc-openapi-gradle-plugin icon indicating copy to clipboard operation
springdoc-openapi-gradle-plugin copied to clipboard

Issue #120 fix - set fork working dir to temp dir

Open hesselapplications opened this issue 11 months ago • 0 comments

Fixes https://github.com/springdoc/springdoc-openapi-gradle-plugin/issues/120

By default gradle-execfork-plugin sets the working dir to the project directory. This causes issues when running generateOpenApiDocs during a gradle build:

Reason: Task ':skeleton-server:forkedSpringBootRun' uses this output of task ':skeleton-server:bootJarMainClassName' without declaring an explicit or implicit dependency. This can lead to incorrect results being produced, depending on what order the tasks are executed.

Using a temporary directory instead of the project dir default resolves this

hesselapplications avatar Mar 28 '24 22:03 hesselapplications