[错误] 无法在项目门户上执行目标:无法解析项目 com.learning:portal:war:1.0.0-SNAPSHOT 的依赖项:在中央找不到工件 com.myapp.Local-2017:jar:1.0(https ://repo.maven.apache.org/maven2 )
在 pom.xml 中:
<dependency>
<groupId>com.myapp.Local</groupId>
<artifactId>Local-2017</artifactId>
<version>1.0</version>
</dependency>
插件:
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-install-plugin</artifactId>
<version>2.5</version>
<executions>
<execution>
<phase>clean</phase>
<configuration>
<repositoryLayout>default</repositoryLayout>
<groupId>com.myapp.Local</groupId>
<artifactId>Local-2017</artifactId>
<version>1.0</version>
<packaging>jar</packaging>
<file>${basedir}/lib/Local.jar</file>
<generatePom>true</generatePom>
</configuration>
<goals>
<goal>install-file</goal>
</goals>
</execution>
</executions>
</plugin>