Closed LeoDroidCoder closed 5 years ago
Hi,
By default Maven does only search for plugins with the groupId org.apache.maven.plugins
and org.codehaus.mojo
when you are using the short "prefix" invocation of a plugin.
To run the depgraph-maven-plugin, you have these three options:
Configure com.github.ferstl
as additional plugin group in your settings.xml
(located in $MAVEN_HOME/conf/
or in $HOME/.m2/
):
<pluginGroups>
<pluginGroup>com.github.ferstl</pluginGroup>
</pluginGroups>
With this setting you can simply run mvn depgraph:graph
. See also the documentation about Plugin Prefix Resolution for further details.
Fully qualify the invocation of the plugin:
mvn com.github.ferstl:depgraph-maven-plugin:3.2.2:graph
(you can omit the version if you have already defined it in the <pluginManagement>
section of your POM file)
Create an explicit plugin execution in your POM file:
<build>
<plugins>
<plugin>
<groupId>com.github.ferstl</groupId>
<artifactId>depgraph-maven-plugin</artifactId>
<version>3.2.2</version>
<executions>
<execution>
<id>create-graph</id>
<!-- use a phase that suits you best -->
<phase>package</phase>
<configuration>
...
</configuration>
<goals>
<goal>graph</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
This example will create the graph automatically when you run mvn package
or mvn install
or mvn deploy
.
HTH
Im closing this issue now. If you have further questions, just contact me again.
Sorry for offtop, but I cannot figure out how to use it with the android studio. As far as I understood, I added a dependency to my Android project
debugImplementation 'com.github.ferstl:depgraph-maven-plugin:3.2.2'
Then I installed the maven with homebrew as:brew install maven
Trying to run it with
mvn depgraph:graph
Which results in an error:How to finally get it work?