gradle execute -DmainClass=com.my.package.MainClassX -Dexec.args="arg1 arg2 arg3"
task execute (type:JavaExec) {
main = System.getProperty("mainClass")
classpath = sourceSets.main.runtimeClasspath
systemProperties System.getProperties()
args System.getProperty("exec.args").split()
}