This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def artifacts = [] | |
| addListener(new TaskExecutionAdapter() { | |
| void afterExecute(Task task, TaskState state) { | |
| if(task in AbstractArchiveTask) { | |
| artifacts << task.outputs.files.singleFile | |
| } | |
| } | |
| }) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| allprojects { | |
| tasks.withType(AbstractArchiveTask) { task -> | |
| outputs.upToDateWhen { false } | |
| task.doLast { | |
| println "\nOutput location: ${archiveName}\n" | |
| } | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // Current way in Groovy | |
| @Immutable | |
| class Person { | |
| String firstName, lastName | |
| int age | |
| Date dateCreated | |
| } | |
| // But: This would be nice | |
| data class Person(String name, String lastName, int age, Date dateCreated) |
NewerOlder