Unfortunately, this is simply not possible at the moment. The reason for this is that STS is using the Gradle tooling API and it only provides very limited control over the process that executes gradle builds. This process is a 'gradle daemon' and is started by the tooling API 'behind the scenes' but the tooling API doesn't provide any means to pass arguments like this.
I agree with you this is a very reasonable thing one might want to do.
There are somewhat related Gradle issues open already:
Maybe you want to vote on these issues :-)
It may be worthwhile creating a separate issue also for STS on the STS issue tracker, although there will not be much I could do until the some progress is made on the tooling API side re passing arguments, options, system properties etc.
Kris De Volder -- SpringSource