The solution is effective only when the project itself can be started normally but cannot be started due to some reasons, including but not limited to the following:

  1. Accidentally deleted files in the project, causing it to fail to start
  2. The project has not been updated for a long time, so it cannot be started after the update
  3. There are many error messages after the project is updated. Failure to start

Common practice:

Based on error information or other error messages, take appropriate measures, such as downloading or updating dependent packages, importing files, and adding plug-ins.

But many times, because of the development environment or the project is not familiar with, can not find the solution to the error message, you also can not start the project because of the abnormal annoyance (such as the tester to fix the bug, the manager to write the code).

In this case, the following methods can help you restart your project in a short time.

Method 1: Download the project again

If there are persistent error messages in the code, remove the existing code and re-download the code directly from the code base. Make sure you back up any code you change

Method 2: Download the dependency package again

If the dependency packages keep displaying error messages, delete all the dependency packages in the existing repository. IDEA will download all the dependency packages again when you restart the project.

Method 3: Ask a colleague to copy the project for use

When you find yourself stuck, copy the project directly from a colleague and use it. There will be no problems in general. Note: the.idea folder is your development environment configuration folder, do not overwrite this folder. Otherwise, your development environment configuration will be owned by your colleagues and will not work properly.

Of course, there will be other configuration files (hosts, for example) or plug-ins (Lombok, for example) in the project, and if you forget, don’t hesitate to ask your colleagues for help.

Suggestion: Programmers like to solve problems by themselves, but they can’t solve them in time. It’s a good idea to ask a colleague for help.