ARTICLE AD BOX
I want to install a project from a public GitHub repository.
I could clone and install it. However, I want to do it in one go with JitPack without storing sources locally.
Example project. My attempt:
mvn dependency:get -Dartifact=com.github.chrissyast:SwingDevTools:0.0.3 -DremoteRepositories=https://jitpack.io -UResult:
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-dependency-plugin:3.6.1:get (default-cli) on project standalone-pom: Couldn't download artifact: org.eclipse.aether.resolution.DependencyResolutionException: The following artifacts could not be resolved: com.github.chrissyast:SwingDevTools:jar:0.0.3 (absent): Could not find artifact com.github.chrissyast:SwingDevTools:jar:0.0.3 in mirror-centralPassing a repo id doesn't change anything.
-DremoteRepositories=jitpack::::https://jitpack.ioMaven 3.9.6. Java 8.
The error is that Maven's mirror config is intercepting the JitPack URL and routing it to mirror-central. You need to tell Maven to also check JitPack, not just pass it as a one-off remote. The cleanest one-liner way is
mvn dependency:get \ -Dartifact=com.github.chrissyast:SwingDevTools:0.0.3 \ -DremoteRepositories=jitpack::::https://jitpack.ioThe :::: syntax is the full id::layout::url format — leaving layout blank uses the default. Giving it an explicit ID (jitpack) prevents it from being swallowed by your mirror rules.
Explore related questions
See similar questions with these tags.

