gradle: Skipping task ':compileJava' as it has no source files

roroco

i try gradle -d compileJava in my try project, and gradle raise "Skipping task ':compileJava' as it has no source files.". the worse thing is that i can't see anything created in build/. i create this project only with running gradle init and creating a "src/Ex.java".

my question is:

How to load default "compileJava" or define my "compileJava" to fix this warning.

Peter Niederwieser

By default, Java source files need to go into src/main/java (or src/test/java for test sources). Either adapt your directory structure accordingly, or reconfigure the source directory as follows:

sourceSets {
    main {
        java {
            srcDirs = ["src"]
        }
    }
}

この記事はインターネットから収集されたものであり、転載の際にはソースを示してください。

侵害の場合は、連絡してくださいdebugcn@gmail.com

編集
0

コメントを追加

0

関連記事

分類Dev

Eclipse - Java - Gradle is skipping jacocoTestReport

分類Dev

GradleのcompileJava DEPENDSON spotlessApplyを作ります

分類Dev

gradle compileJava error: package org.junit does not exist

分類Dev

how to tell rsync to preserve time stamp on files when source tree has a mounted point

分類Dev

Unzip skipping all files when extracting archive

分類Dev

Gradle Heroku Task 'stage'

分類Dev

Modify an existing gradle task

分類Dev

Modify an existing gradle task

分類Dev

Visualize gradle task dependencies

分類Dev

GradleにcompileJavaタスクを追加するプラグイン

分類Dev

Gradle compileJavaタスク警告:[オプション]ブートストラップクラスパスが-source 1.6と組み合わせて設定されていません

分類Dev

Passing in tags to Gradle cucumber task

分類Dev

Override Task in build.gradle

分類Dev

Passing parameter to custom Gradle task

分類Dev

Convert ant signJar task to gradle

分類Dev

IntelliJアイデア - のGradle:実行タスクに失敗しました ':compileJava'

分類Dev

gradleビルド、失敗タスク ':compileJava'の実行に失敗しました

分類Dev

timing loading of clojure source files

分類Dev

Command to Download Source Files in FreeBSD

分類Dev

How to ignore source files in bower

分類Dev

Use non-static method as source for Task

分類Dev

Tell a Task to wait until Timer has stopped

分類Dev

'PlaintextCorpusReader' object has no attribute 'files'

分類Dev

Adobe Source Code Pro has two extensions?

分類Dev

Not Creating the File when source has 0 rows

分類Dev

Adobe Source Code Pro has two extensions?

分類Dev

Gradle build: Execution failed for task ':app:lint'

分類Dev

Gradle build: Execution failed for task ':app:lint'

分類Dev

Android - what is gradle task connectedCheck used for

Related 関連記事

  1. 1

    Eclipse - Java - Gradle is skipping jacocoTestReport

  2. 2

    GradleのcompileJava DEPENDSON spotlessApplyを作ります

  3. 3

    gradle compileJava error: package org.junit does not exist

  4. 4

    how to tell rsync to preserve time stamp on files when source tree has a mounted point

  5. 5

    Unzip skipping all files when extracting archive

  6. 6

    Gradle Heroku Task 'stage'

  7. 7

    Modify an existing gradle task

  8. 8

    Modify an existing gradle task

  9. 9

    Visualize gradle task dependencies

  10. 10

    GradleにcompileJavaタスクを追加するプラグイン

  11. 11

    Gradle compileJavaタスク警告:[オプション]ブートストラップクラスパスが-source 1.6と組み合わせて設定されていません

  12. 12

    Passing in tags to Gradle cucumber task

  13. 13

    Override Task in build.gradle

  14. 14

    Passing parameter to custom Gradle task

  15. 15

    Convert ant signJar task to gradle

  16. 16

    IntelliJアイデア - のGradle:実行タスクに失敗しました ':compileJava'

  17. 17

    gradleビルド、失敗タスク ':compileJava'の実行に失敗しました

  18. 18

    timing loading of clojure source files

  19. 19

    Command to Download Source Files in FreeBSD

  20. 20

    How to ignore source files in bower

  21. 21

    Use non-static method as source for Task

  22. 22

    Tell a Task to wait until Timer has stopped

  23. 23

    'PlaintextCorpusReader' object has no attribute 'files'

  24. 24

    Adobe Source Code Pro has two extensions?

  25. 25

    Not Creating the File when source has 0 rows

  26. 26

    Adobe Source Code Pro has two extensions?

  27. 27

    Gradle build: Execution failed for task ':app:lint'

  28. 28

    Gradle build: Execution failed for task ':app:lint'

  29. 29

    Android - what is gradle task connectedCheck used for

ホットタグ

アーカイブ