Passing arguments to my program in Gradle run task via Buildship

I have imported a small Java command line tool using the eclipse gradle import. Everything works fine (compile, run, create image,…). However I am unable to pass command line arguments to my programm when using the gradle run configuration from within eclipse. Similar to what i would do on the command line:

gradle run --args="-foo bar"

I am not sure what the right way to use the toolchain actually is. But I am trying to create a gradle run config from within eclipse and then set my programms arguments in that run config.

I have tried to put them on the Gradle Tasks tab in the task list after my task like

  • run -foo bar
  • run --args=“-foo bar”

However gradle always interprets the part after run as additional gradle tasks which obiously are not there. Any tips welcome as I very likely miss something blatantly obvious…

Eclipse 4.19.
Buildship 3.1.5
Gradle 6.8.3