私は 2 つの Java プロジェクトを持っています:payment-common
とpayment-service
. payment-common
私は追加しましたmaven-siurce-plugin
:
<project>
<builds>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
<executions>
<execution>
<id>attach-sources</id>
<goals>
<goal>jar</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>
を実行すると、ターゲットに次mvn clean package
のように表示されます。sources.jar
次の後に、リモートリポジトリにこの .jar ファイルも表示されますmvn clean deploy
。
プロジェクトに次の依存関係がありますpayment-service
:
<dependency>
<groupId>com.***</groupId>
<artifactId>payment-common</artifactId>
<version>1.540.0-SNAPSHOT</version>
</dependency>
Idea でソースをダウンロードしようとすると、次のエラーが発生します。
その後。を実行するmvn clean install
と、ソースを正常にダウンロードできます。私は何を間違っていますか?
UPD : pom.xml のリポジトリ:
<repositories>
<repository>
<id>cloudfront-snapshots</id>
<name>***</name>
<url>https://maven.***.net/</url>
</repository>
<repository>
<id>jcenter-snapshots</id>
<name>jcenter</name>
<url>https://jcenter.bintray.com/</url>
</repository>
<repository>
<id>maven.***</id>
<url>s3://***-maven-repo/</url>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>maven.***</id>
<url>s3://***-maven-repo/</url>
</pluginRepository>
</pluginRepositories>
<distributionManagement>
<repository>
<id>maven.***</id>
<url>s3://***-maven-repo/</url>
</repository>
<snapshotRepository>
<id>maven.***</id>
<url>s3://***-maven-repo/</url>
</snapshotRepository>
</distributionManagement>