0.spring boot 官方指导:
https://spring.io/guides/gs/spring-boot/
JDK 1.8 or later
You can also import the code straight into your IDE:
1.java安装
http://www.oracle.com/technetwork/java/javase/downloads/jdk10-downloads-4416644.html
2.maven 安装
https://maven.apache.org/download.cgi
环境变量:
path=C:\apache-maven-3.5.3-bin\apache-maven-3.5.3\bin
echo %JAVA_HOME%
C:\Program Files\Java\jdk1.7.0_51
C:\Program Files\Java\jdk1.7.0_51
3.下载spring boot 测试代码:
Download and unzip the source repository for this guide, or clone it using
Git:
git clone https://github.com/spring-guides/gs-spring-boot.git
代码的complete目录下:
mvn package && java -jar target/gs-spring-boot-0.1.0.jar
4.成功:
http://localhost:8080/
Greetings from Spring Boot!