I have a Java application that runs with a custom gradle task and the application requires some arguments upon being invoked. These are:
programName ( string
If you want to use the same set of arguments all the time, the following is all you need.
run { args = ["--myarg1", "--myarg2"] }