Created
October 2, 2015 04:45
-
-
Save gki/e610babd2c833ba83c3a to your computer and use it in GitHub Desktop.
[Gradle] add pre-action, post-action
This file contains 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
task mytask { | |
doFirst { | |
println "doFirst" | |
} | |
} | |
mytask.doLast { | |
println "doLast" | |
} | |
mytask << { | |
println "doLast by <<" // this is same as mytask.doLast {} | |
} | |
// add action to existing task | |
check.doFirst { | |
println "doFirst for check!" | |
} | |
check.doLast { | |
println "doLast for check!" | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment