Hi Daniel,

we have the same issue in spock, when a file produced by the build is
used by gradle later on
the daemon keeps it locked.

Make sure that no daemon is already running,

`gradlew --stop`

then

`gradlew clean dist --no-daemon` should work

Cheers

-Leonard

P.S. As Paul suggested I'd advice to disabled the daemon via
gradle.properties: `org.gradle.daemon=false`


Am 28.11.2017 um 07:31 schrieb Daniel.Sun:
> I tried `gradlew dist --no-daemon`, still failed...
>
> ---------------------------
> FAILURE: Build failed with an exception.
>
> * What went wrong:
> java.io.IOException: Unable to delete file:
> D:\_APPS\git_apps\groovy\target\bootstrap\groovy-3.0.0-SNAPSHOT-bootstrap.jar
>> Unable to delete file:
>> D:\_APPS\git_apps\groovy\target\bootstrap\groovy-3.0.0-SNAPSHOT-bootstrap.jar
> * Try:
> Run with --stacktrace option to get the stack trace. Run with --info or
> --debug option to get more log output. Run with --scan to get full insights.
>
> * Get more help at https://help.gradle.org
>
> BUILD FAILED in 2m 42s
> 97 actionable tasks: 77 executed, 20 up-to-date
>
> Publishing build scan...
> https://gradle.com/s/efe6pamkllmxo
>
>
>
> --
> Sent from: http://groovy.329449.n5.nabble.com/Groovy-Dev-f372993.html

Reply via email to