Dynamically created task of type Copy is always UP-TO-DATE

前端 未结 4 601
一整个雨季
一整个雨季 2020-12-16 22:48

I\'ve prepared a very simple script, that illustrates the problem I see using Gradle 1.7 (need to stick with it because of some plugins not yet supporting newer versions).

4条回答
  •  半阙折子戏
    2020-12-16 23:41

    I think the following Gradle User Guide quote answers my question the best:

    Secondly, the copy() method can not honor task dependencies when a task is used as a copy source (i.e. as an argument to from()) because it's a method and not a task. As such, if you are using the copy() method as part of a task action, you must explicitly declare all inputs and outputs in order to get the correct behavior.

提交回复
热议问题