<<
による記法は Gradle 3.2 で非推奨となり、Gradle 5.0 で廃止になったようです。
The left shift operator on the Task interface - Gradle 3.2 Release Notes
With this version of Gradle, the left shift operator on the Task interface is deprecated and is scheduled to be removed with the next major release. There's no direct replacement for the left shift operation. Please use the existing methods doFirst and doLast to define task actions.
Upgrading your build from Gradle 4.x to 5.0
- << for task definitions no longer works. In other words, you can not use the syntax task myTask << { … }.
Use the Task.doLast() method instead, like this:
task myTask {
doLast {
...
}
}
上述のように Task.doLast()
を代わりに使用するのが適切かと思います。
groovy
1task hello {
2 doLast {
3 println 'Hello world!'
4 }
5}
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。
2019/05/04 07:37