DiscordIPC icon indicating copy to clipboard operation
DiscordIPC copied to clipboard

Gradle not finding the project

Open ghost opened this issue 6 years ago • 9 comments

Whenever I try to use this project with gradle, it cannot find it.

Heres the error: Could not find com.jagrosh:DiscordIPC:0.4. Searched in the following locations: - file:/Users/myuser/.gradle/caches/forge_gradle/bundeled_repo/com/jagrosh/DiscordIPC/0.4/DiscordIPC-0.4.pom - file:/Users/myuser/.gradle/caches/forge_gradle/bundeled_repo/com/jagrosh/DiscordIPC/0.4/DiscordIPC-0.4.jar - https://files.minecraftforge.net/maven/com/jagrosh/DiscordIPC/0.4/DiscordIPC-0.4.pom - https://files.minecraftforge.net/maven/com/jagrosh/DiscordIPC/0.4/DiscordIPC-0.4.jar - https://libraries.minecraft.net/com/jagrosh/DiscordIPC/0.4/DiscordIPC-0.4.jar - https://repo.maven.apache.org/maven2/com/jagrosh/DiscordIPC/0.4/DiscordIPC-0.4.pom - https://repo.maven.apache.org/maven2/com/jagrosh/DiscordIPC/0.4/DiscordIPC-0.4.jar Required by: project :

ghost avatar Sep 15 '19 00:09 ghost

What repositories do you have in gradle?

Sanduhr32 avatar Sep 15 '19 11:09 Sanduhr32

It looks like you forgot to add jcenter to the repositories section:

repositories {
    jcenter()
}

jagrosh avatar Sep 16 '19 16:09 jagrosh

I've already tried that, heres my build.gradle file https://pastebin.com/WTLNk3eD

ghost avatar Sep 17 '19 14:09 ghost

Same issue here

build.gradle: https://pastebin.com/g3yNJeUw Error: Could not resolve: com.jagrosh:DiscordIPC:0.4

lukeacat avatar Feb 14 '21 16:02 lukeacat

Hey @LimaBean2091 and @lukeacat! You need to add the JCenter repository to the repositories section of the build.gradle file itself (which does not yet exist in your gradle files) and not to the one inside of thebuildscript block.

On a related note: @jagrosh, since it was announced that JCenter is shutting down, are there any plans to offer this library through another repository?

crykn avatar Feb 16 '21 09:02 crykn

Haha, I already fixed this long ago, thanks for the mention anyways! I forgot to post the sulution!

EDIT: About JCenter, I don't feel like it should be moved yet, becuase To clarify, the JCenter repository will keep serving packages for 12 months until February 1st 2022. Only the JCenter REST API and UI will be sunsetted on May 1st 2021. and moving it right now would be kinda unproductive :P I don't know though.

lukeacat avatar Feb 16 '21 17:02 lukeacat

Hey there! Wanted to check in on the status of this, has DiscordIPC been made available in mavenCentral()? Obviously jcenter() isn't serving packages anymore so I can't use it in my project.

blueysh avatar Apr 26 '22 12:04 blueysh

You can use jitpack

jagrosh avatar Apr 26 '22 15:04 jagrosh

Ah thanks!

blueysh avatar Apr 26 '22 15:04 blueysh