Java: Add source plugin (#1925)

This ensures that a `mvn install` will also post source JARs into the
local repository, helping developers navigate through the source code
while debugging.
This commit is contained in:
Bruno Borges
2023-07-10 19:29:40 +01:00
committed by GitHub
parent c0d770901e
commit 5854b1df5b
+18 -3
View File
@@ -1,7 +1,8 @@
<?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">
<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>
@@ -441,6 +442,20 @@
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
<version>3.3.0</version>
<executions>
<execution>
<id>attach-sources</id>
<phase>verify</phase>
<goals>
<goal>jar-no-fork</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
@@ -668,7 +683,7 @@
<licenseHeader>
<content>// Copyright (c) Microsoft. All rights reserved.</content>
</licenseHeader>
<toggleOffOn/>
<toggleOffOn />
</java>
</configuration>
</plugin>