Eclipse上必需的项目在maven clean build之后仍然消失

时间:2019-04-24 19:31:59

标签: eclipse maven

我有一个pom,如下。

<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 
 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>

<groupId>com.kt.web</groupId>
<artifactId>KT-web</artifactId>
<version>1.0</version>

<name>ktweb</name>
<description>Web App</description>

<parent>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-starter-parent</artifactId>
    <version>1.5.9.RELEASE</version>
    <relativePath /> <!-- lookup parent from repository -->
</parent>

<properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
    <java.version>1.8</java.version>
    <jstl.version>1.2</jstl.version>
    <tiles.version>2.2.2</tiles.version>
    <springsecurity.version>4.0.4.RELEASE</springsecurity.version>
</properties>

<repositories>
 ...
</repositories>

<dependencies>
 ...
</dependencies>

<build>
    <plugins>
        <plugin>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-maven-plugin</artifactId>
        </plugin>
    </plugins>
    <finalName>kt-web</finalName>
</build>


<dependencyManagement>
    <dependencies>
        <dependency>
            <groupId>com.kts.common</groupId>
            <artifactId>kt-common</artifactId>
            <version>1.0</version>
        </dependency>
    </dependencies>
</dependencyManagement>

每当我运行maven clean install时,Eclipse上的“ kt-common”必需项目就会消失。 kt-common存在于Eclipse项目中。

该如何避免将其从日蚀所需的项目中删除?

0 个答案:

没有答案