|
1 | 1 | <?xml version="1.0" encoding="UTF-8"?> |
2 | 2 | <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" |
3 | 3 | xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> |
4 | | -<modelVersion>4.0.0</modelVersion> |
| 4 | + <modelVersion>4.0.0</modelVersion> |
5 | 5 |
|
6 | | - <artifactId>spring-boot-demo-war</artifactId> |
| 6 | + <artifactId>spring-boot-demo-war</artifactId> |
| 7 | + <version>1.0.0-SNAPSHOT</version> |
| 8 | + <!-- 若需要打成 war 包,则需要将打包方式改成 war --> |
| 9 | + <packaging>war</packaging> |
| 10 | + |
| 11 | + <name>spring-boot-demo-war</name> |
| 12 | + <description>Demo project for Spring Boot</description> |
| 13 | + |
| 14 | + <parent> |
| 15 | + <groupId>com.xkcoding</groupId> |
| 16 | + <artifactId>spring-boot-demo</artifactId> |
7 | 17 | <version>1.0.0-SNAPSHOT</version> |
8 | | - <!-- 若需要打成 war 包,则需要将打包方式改成 war --> |
9 | | - <packaging>war</packaging> |
10 | | - |
11 | | -<name>spring-boot-demo-war</name> |
12 | | -<description>Demo project for Spring Boot</description> |
13 | | - |
14 | | -<parent> |
15 | | -<groupId>com.xkcoding</groupId> |
16 | | -<artifactId>spring-boot-demo</artifactId> |
17 | | -<version>1.0.0-SNAPSHOT</version> |
18 | | -</parent> |
19 | | - |
20 | | -<properties> |
21 | | -<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> |
22 | | -<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding> |
23 | | -<java.version>1.8</java.version> |
24 | | -</properties> |
25 | | - |
26 | | - <dependencies> |
27 | | - <dependency> |
28 | | - <groupId>org.springframework.boot</groupId> |
29 | | - <artifactId>spring-boot-starter-web</artifactId> |
30 | | - </dependency> |
31 | | - |
32 | | - <!-- 若需要打成 war 包,则需要将 tomcat 引入,scope 设置为 provided --> |
33 | | - <dependency> |
34 | | - <groupId>org.springframework.boot</groupId> |
35 | | - <artifactId>spring-boot-starter-tomcat</artifactId> |
36 | | - <scope>provided</scope> |
37 | | - </dependency> |
38 | | - |
39 | | -<dependency> |
40 | | -<groupId>org.springframework.boot</groupId> |
41 | | -<artifactId>spring-boot-starter-test</artifactId> |
42 | | -<scope>test</scope> |
43 | | -</dependency> |
44 | | -</dependencies> |
45 | | - |
46 | | -<build> |
47 | | -<finalName>spring-boot-demo-war</finalName> |
48 | | -<plugins> |
49 | | -<plugin> |
50 | | -<groupId>org.springframework.boot</groupId> |
51 | | -<artifactId>spring-boot-maven-plugin</artifactId> |
52 | | -</plugin> |
53 | | -</plugins> |
54 | | -</build> |
| 18 | + </parent> |
| 19 | + |
| 20 | + <properties> |
| 21 | + <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> |
| 22 | + <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding> |
| 23 | + <java.version>1.8</java.version> |
| 24 | + </properties> |
| 25 | + |
| 26 | + <dependencies> |
| 27 | + <dependency> |
| 28 | + <groupId>org.springframework.boot</groupId> |
| 29 | + <artifactId>spring-boot-starter-web</artifactId> |
| 30 | + </dependency> |
| 31 | + |
| 32 | + <!-- 若需要打成 war 包,则需要将 tomcat 引入,scope 设置为 provided --> |
| 33 | + <dependency> |
| 34 | + <groupId>org.springframework.boot</groupId> |
| 35 | + <artifactId>spring-boot-starter-tomcat</artifactId> |
| 36 | + <scope>provided</scope> |
| 37 | + </dependency> |
| 38 | + |
| 39 | + <dependency> |
| 40 | + <groupId>org.springframework.boot</groupId> |
| 41 | + <artifactId>spring-boot-starter-test</artifactId> |
| 42 | + <scope>test</scope> |
| 43 | + </dependency> |
| 44 | + </dependencies> |
| 45 | + |
| 46 | + <build> |
| 47 | + <finalName>spring-boot-demo-war</finalName> |
| 48 | + <plugins> |
| 49 | + <plugin> |
| 50 | + <groupId>org.springframework.boot</groupId> |
| 51 | + <artifactId>spring-boot-maven-plugin</artifactId> |
| 52 | + </plugin> |
| 53 | + <plugin> |
| 54 | + <groupId>org.apache.maven.plugins</groupId> |
| 55 | + <artifactId>maven-war-plugin</artifactId> |
| 56 | + <version>2.6</version> |
| 57 | + <configuration> |
| 58 | + <failOnMissingWebXml>false</failOnMissingWebXml> |
| 59 | + </configuration> |
| 60 | + </plugin> |
| 61 | + </plugins> |
| 62 | + </build> |
55 | 63 |
|
56 | 64 | </project> |
0 commit comments