diff --git a/devtools/gradle/gradle-application-plugin/src/main/java/io/quarkus/gradle/tasks/QuarkusDev.java b/devtools/gradle/gradle-application-plugin/src/main/java/io/quarkus/gradle/tasks/QuarkusDev.java index ae3555a09e6d4..ab174702a915f 100644 --- a/devtools/gradle/gradle-application-plugin/src/main/java/io/quarkus/gradle/tasks/QuarkusDev.java +++ b/devtools/gradle/gradle-application-plugin/src/main/java/io/quarkus/gradle/tasks/QuarkusDev.java @@ -346,7 +346,9 @@ public QuarkusDev extensionJvmOptions(Action ac @TaskAction public void startDev() { if (!sourcesExist()) { - throw new GradleException("The `src/main/java` directory is required, please create it."); + throw new GradleException( + "At least one source directory (e.g. src/main/java, src/main/kotlin) should contain sources before starting Quarkus in dev mode when using Gradle. " + + "Please initialize your project a bit further before restarting Quarkus in dev mode."); } if (!classesExist()) {