This message was deleted.
# community-support
s
This message was deleted.
v
Yes, that gives it to the Gradle process. You cannot directly give system properties to the
run
task. You need to configure that from your build script. You can for example read the system property and forward its value, or you could also define Gradle property you forward as system property.
s
You can pass command line arguments though, with the
--args
option.
v
Which does not help though to set system properties
s
No, just thought I’d mention it, if it somehow helped with the end goal
i
Is there a way to create a JavaExec task that uses exactly the same config as the application's run task and just add some JVM arg there?
Something similar to this?
Copy code
val runModified by tasks.registering(JavaExec::class) {
    copyConfigurationFrom(tasks["run"])

    description = "Modified"
    jvmArg("-D…")
}
v
Not that I'm aware of, you need to configure it yourself. But you can look at the application plugin how it configures it