Generate dependency list 85/99485/1
authorTimoney, Dan (dt5972) <dtimoney@att.com>
Wed, 11 Dec 2019 13:16:13 +0000 (08:16 -0500)
committerTimoney, Dan (dt5972) <dtimoney@att.com>
Wed, 11 Dec 2019 13:16:13 +0000 (08:16 -0500)
Generate list of direct dependencies for repository and publish to Nexus.

Change-Id: If8a89cc6d3a46e896159d30682a7196df45dd258
Issue-ID: CCSDK-1986
Signed-off-by: Timoney, Dan (dt5972) <dtimoney@att.com>
.gitignore
pom.xml

index d66d735..7943e83 100755 (executable)
@@ -40,3 +40,6 @@ yang-gen-sal/
 sdnc-northbound_bdio.jsonld
 blackDuckHubProjectName.txt
 blackDuckHubProjectVersionName.txt
+
+# Generated dependencies list
+direct-dependencies.txt
diff --git a/pom.xml b/pom.xml
index b376605..c3df62b 100644 (file)
--- a/pom.xml
+++ b/pom.xml
             </build>
 
         </profile>
-
+        <profile>
+            <id>dependency-list</id>
+            <build>
+                <plugins>
+                    <plugin>
+                        <groupId>com.github.ferstl</groupId>
+                        <artifactId>depgraph-maven-plugin</artifactId>
+                        <executions>
+                            <execution>
+                                <phase>validate</phase>
+                                <inherited>false</inherited>
+                                <goals>
+                                    <goal>aggregate</goal>
+                                </goals>
+                            </execution>
+                        </executions>
+                    </plugin>
+                    <plugin>
+                        <groupId>org.codehaus.mojo</groupId>
+                        <artifactId>build-helper-maven-plugin</artifactId>
+                        <executions>
+                            <execution>
+                                <id>attach-artifacts</id>
+                                <phase>package</phase>
+                                <inherited>false</inherited>
+                                <goals>
+                                    <goal>attach-artifact</goal>
+                                </goals>
+                                <configuration>
+                                    <artifacts>
+                                        <artifact>
+                                            <file>${dependency-list.file}</file>
+                                            <type>txt</type>
+                                            <classifier>dependencies</classifier>
+                                        </artifact>
+                                    </artifacts>
+                                </configuration>
+                            </execution>
+                        </executions>
+                    </plugin>
+                </plugins>
+            </build>
+        </profile>
     </profiles>
 
     <build>