Search code examples
javamavenjitpack

ERROR: No build artifacts found - Maven Jitpack


Note: Before you mark this as duplicate please check all information as after 4 hours of search I couldn't find any close cases. All results were about Android Library or Gradle which is not correct on this case.

Links:

Build Log: https://jitpack.io/xyz/agmdev/AGMCore/3.3.1/build.log

Github Source: https://github.com/Ashenguard/AGMCore

Error:

Exit code: 0
Timed out after 20 min

ERROR: No build artifacts found
Project: Maven - Spigot
Version: 3.3.1

Today after finishing the coding, compiling, testing (All of them were successful on my PC) I decided it's time to upload it on Github and create the 3.3.1 release on jitpack.io so I or any other developer can use it in further projects as dependency.

Everything was ok until I started the new project depending on the new code I just uploaded. But I faced the dependency not found on my IDE (Intelij) and I thought it is a connection issue or something similar, But after troubleshooting, I got to the Build being failure on jitpack.io.

Before you ask, I did test mvn install and it worked fine without any issue on my PC, but for some reason that I'm not aware of, jitpack fails... What confused me more only thing that has been changed on pom.xml since the last successful build, is the version number

Possible issues that were not the issue in this case. (I'll update the list)

  • Packaging not being jar which was, Same as previous versions.
  • useIncrementalCompilation was not the issue as well.

Solution

  • After months of head-scratching, I found out the issue.

    The issue was that Jitpack was not able to find one of the plugins I have used in the project, After adding the maven as a plugin repository the issue is gone and Jitpack is doing its job.

        <pluginRepositories>
            <pluginRepository>
                <id>maven-snapshots</id>
                <url>https://repository.apache.org/content/repositories/snapshots/</url>
            </pluginRepository>
            <pluginRepository>
                <id>maven-shade-plugin</id>
                <url>https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-shade-plugin</url>
            </pluginRepository>
        </pluginRepositories>