에 파일 가져 오기가 실패합니다.오류 가져 오기 라이브러리가 그 일을 할 때 나는 그러나, 속성 파일에 pom.xml 파일에서 내 버전을 이동하기 위해 노력하고있어 pom.xml 파일
내 pom.xml 파일과 같은 수 있습니다 : 오류가 pom.xml 파일에 표시되지 않습니다
<?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.trial</groupId>
<artifactId>books</artifactId>
<version>1.0-SNAPSHOT</version>
<build>
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>properties-maven-plugin</artifactId>
<version>1.0.0</version>
<executions>
<execution>
<phase>initialize</phase>
<goals>
<goal>read-project-properties</goal>
</goals>
<configuration>
<files>
<file>${basedir}/versions.properties</file>
</files>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
<dependencies>
<!-- SPRING -->
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-web</artifactId>
<version>${springframework.version}</version>
</dependency>
...
</dependencies>
</project>
있지만, 가져 오기가 실패 시작이 (가 잘 작동 될 때 속성 곳 pom.xml 파일에 설정) :
import org.springframework.beans.factory.annotation.Autowired;
예외 :
012 :Error:(6, 52) java: package org.springframework.beans.factory.annotation does not exist
versions.properties처럼 보이는 3,516,
springframework.version = 5.0.1.RELEASE
무슨 일입니까? 내가 도대체 뭘 잘못하고있는 겁니까?
감사합니다이 같은 것을 사용할 수있어 많은
가능한 중복 : [메이븐의 https://stackoverflow.com/questions/40114869/maven-pom-file-externalizing-dependency-versions-to-a-properties-file –
가능한 중복 등록 정보 파일 (https://stackoverflow.com/questions/40114869/maven-pom-file-externalizing-dependency-versions-to-a-properties-file) –