We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 05b24db commit 19afef8Copy full SHA for 19afef8
1 file changed
orb-java-example/build.gradle.kts
@@ -17,5 +17,12 @@ tasks.withType<JavaCompile>().configureEach {
17
}
18
19
application {
20
- mainClass = "com.withorb.api.example.Main"
+ // Use `./gradlew :orb-java-example:run` to run `Main`
21
+ // Use `./gradlew :orb-java-example:run -Dexample=Something` to run `SomethingExample`
22
+ mainClass = "com.withorb.api.example.${
23
+ if (project.hasProperty("example"))
24
+ "${project.property("example")}Example"
25
+ else
26
+ "Main"
27
+ }"
28
0 commit comments