Jump to content

The system cannot find the path specified. Error: could not find or load main class org.gradle.wrapper.GradleWrapperMain


Recommended Posts

possibly related to this post

fair warning, I'm almost completely new to modding, having only gotten far enough to implement a few items and some untextured blocks. Even that much I only accomplished thanks to CJMinecraft's tutorials (available here), so if I say or do something 'stupid', please have patience.

I tried to install/setup a workspace on a new computer I just got not too long ago, but for some reason, the same steps in the tutorial I'm following (and which I used to set a workspace up on my old computer), well, they aren't working. here's what I did before I got an error (note: This list is only the steps I went through up until I initially got the error in step 5; as such, anything I did to try to resolve the error isn't included):

  1. I installed 64-bit Java
  2. I set the Java_home environment variable to point to it
  3. I downloaded the MDK and extracted it to the folder I want to set up as my workspace
  4. I opened up command prompt at the location by calling "start CMD" in powerShell there
  5. I tried to run the command gradlew SetupDecompWorkspace eclipse, but got the error "The system cannot find the path specified. Error: could not find or load main class org.gradle.wrapper.GradleWrapperMain"

after getting that error, I tried a few things to try to resolve it, including (but not limited to) inspecting gradle-wrapper.jar to see if it was where it's supposed to be and had the method in question (spoiler alert, it did), trying again after deleting .gradle from my user directory, and repeating steps 3-5 in various locations (It worked okay on my desktop for some reason, despite the only difference between the folders' permissions being that one inherits from my user directory and one inherits directly from desktop). Try as I might, I can't figure out why it won't setup in the folder I want. Please help.

additional information:

A comment thread on CJMinecraft's video, in which I tried to resolve this with his help, can be found here

a screenshot of my most recent PowerShell & CMD session, in addition to being attached to this post, can be found here

most recent shell session as of 05-24-2018 0822AM.PNG

Link to comment
Share on other sites

Try gradlew.bat instead of just gradlew.

Apparently I'm a complete and utter jerk and come to this forum just like to make fun of people, be confrontational, and make your personal life miserable.  If you think this is the case, JUST REPORT ME.  Otherwise you're just going to get reported when you reply to my posts and point it out, because odds are, I was trying to be nice.


Exception: If you do not understand Java, I WILL NOT HELP YOU and your thread will get locked.


DO NOT PM ME WITH PROBLEMS. No help will be given.

Link to comment
Share on other sites

3 hours ago, Draco18s said:

Try gradlew.bat instead of just gradlew.

tried that, but thanks nonetheless

1 hour ago, diesieben07 said:

Remove those crazy letters from your path.

Good point. I don't think that "-" is even supposed to be there in the first place (I think Windows might have added it because the "workspaces" wouldn't fit on one line when I was naming the folder. Even if I did it, it's not necessary), for instance, so that's probably the problem. I'll give it a try when I'm back on that computer. Thanks :)

Link to comment
Share on other sites

okay that fixed it. Thanks diesieben! I removed the non-alphanumeric characters (besides the spaces and periods) and it was able to find the jar without issue. I also appear to have avoided the error I got when I tried to setup a workspace under my desktop folder (I forget what the error was, but it's irrelevant to my situation since I don't want to put my workspace there anyway).

moderation, please close this. I don't think I need any more help with this, but if it turns out I do, I'd rather start a new thread and reference this one. thanks everyone!


Edit: ran into this again today when I tried to run this from under a folder with the "&" character. I guess I use that character far too often; I'm just glad I bookmarked this thread to remind me how to fix it. Now I just need to go move my OneDrive folder, again! SMH...

Edited by macks2008
update: it happened again. At least I know how to fix it this time!
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Create New...

Important Information

By using this site, you agree to our Terms of Use.