Preface
IntelliJ IDEA compilation and generation of Jar packages are different from those of Eclipse. How to build this Maven Java recommendation engine project to generate a Jar package does indeed search for a lot of information, and there are successes and failures, this verification method is recorded and shared with friends who encounter such problems.
OS: Windows 8.1
JRE: 1.7.0
Development Tool: IntelliJ IDEA 13.1.1
1. Select the Java project name and selectFile->Project structure... Ctrl + Alt + Shift + S
2. In the pop-up window, select"Artifacts", Click"+"Select jar, and then select"From modules with dependencies".
3. Configure"Main Class".
After the configuration is complete, click OK to go to the next step.
4. Select"Build On make"(Jar is automatically output during the make project)
5. the above steps complete the configuration of generating the Jar package during compilation, and then selectBuild->Make project.
Run the Jar package in the project output directory and run the command to run the Jar file.