semudu
semudu

Reputation: 390

Error: Could not find or load main class Tool

My configuration is below:

I use Spring Tool Suite 3.7.1.RELEASE (Build Id: 201510041213).

I did all settings about Java, Maven and STS but when I try to run any Maven command, STS is throwing this exception, although it runs on terminal correctly.

Upvotes: 0

Views: 1137

Answers (1)

Subler
Subler

Reputation: 657

I had a project that I had been developing on STS version 3.6.4.RELEASE, but when I downloaded STS 3.7.1.RELEASE on a different PC, imported the project and tried to build/clean/... with maven, it would show this error (Error: Could not find or load main class Tool) as well.

What I did was copy the version 3.6.4.RELEASE from one computer to the other computer, and then I could build the project. I then proceeded to update STS through eclipse rather than downloading from the site, and now I'm running 3.7.1.RELEASE on the second computer and the project continues to be able to launch now :)

AFAIK these were my steps then:

  1. Get older version of STS (3.6.4.RELEASE in my case, that i had been using on a different pc, copied it and deleted ini file because it caused an error at startup)
  2. Import project
  3. Update STS through eclipse
  4. Maven now builds the project without errors

Hope this helps!

Upvotes: 1

Related Questions