We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 6652a57 commit f3878feCopy full SHA for f3878fe
.github/scripts/java-gradle-bootstrap.sh
@@ -52,12 +52,15 @@ def exampleFiles = examplesDir.exists()
52
tasks.register('runExample', JavaExec) {
53
group = 'examples'
54
description = 'Run a single Java example (use -PexampleClass=<FQN>)'
55
+ classpath = sourceSets.examples.runtimeClasspath
56
+
57
doFirst {
58
if (!project.hasProperty('exampleClass')) {
59
throw new GradleException("Missing -PexampleClass=<fully.qualified.ClassName>")
60
}
- // Set it to a concrete String value at execution time
61
+ // Set to a concrete String value at execution time
62
mainClass.set(project.property('exampleClass').toString())
63
+ }
64
65
66
// Create a JavaExec task per discovered example: run_<FQN with dots replaced by underscores>
0 commit comments