Skip to content

Commit afad1bb

Browse files
chore(internal): allow running specific example from cli
1 parent 9e435d6 commit afad1bb

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

orb-kotlin-example/build.gradle.kts

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,12 @@ dependencies {
88
}
99

1010
application {
11-
mainClass = "com.withorb.api.example.MainKt"
11+
// Use `./gradlew :orb-kotlin-example:run` to run `Main`
12+
// Use `./gradlew :orb-kotlin-example:run -Dexample=Something` to run `SomethingExample`
13+
mainClass = "com.withorb.api.example.${
14+
if (project.hasProperty("example"))
15+
"${project.property("example")}ExampleKt"
16+
else
17+
"MainKt"
18+
}"
1219
}

0 commit comments

Comments
 (0)