Create private Gradle task which is not visible on task list

后端 未结 1 1051

Is it possible to create private Gradle task which is not visible on task list (gradlew tasks)?

相关标签:
1条回答
  • 2021-01-17 11:27

    Gradle doesn't support marking a task as "private". However, gradle tasks will only show a task if it either has task.group set, or no other task depends on it. The idea behind this is that such a task is likely meant to be executed directly by the user. In contrast, gradle tasks --all will show all tasks.

    0 讨论(0)
提交回复
热议问题