Hi, Thanks for the reply and I agree with the logical circular dependency argument. But I still believe that this is valid test/use case for a Maven plugin being developed.
The profile idea 'self-test/run' works in this case for what I'm working on; but I think main reason is that logic here only applies to Java sources and the default is process-sources. In this, the plugin needs to run against itself before any release. Regards, Behrooz On Mon, Jul 18, 2016 at 1:00 PM, Karl Heinz Marbaise <khmarba...@gmx.de> wrote: > > Hi, > > trying to run your own plugin which you are developing within the same > project will not work cause that already sounds like a circle .. > > That's the reason to use invoker-plugin to have full fledged project > running as tests... > > A profile will not really help, cause you need to do a `mvn install` first > and than run your project with something like `mvn -Pself-testing verify` ? > Not a good idea? > > And finally this is not best practice... > > What you can do is to define a previous released version of your plugin in > your pom ...That's what for example maven-invoker-plugin itself is doing.. > ;-) > > > Kind regards > Karl Heinz Marbaise > > On 7/18/16 9:43 AM, Behrooz Nobakht wrote: > >> Hi, >> >> I am developing a Maven Plugin and trying to follow documentation[1] to >> use >> maven-invoker-plugin >> from the auto-generated profile 'run-its' to run an execution of the >> plugin >> under dev on itself. >> >> As an example, let's consider mojouas/license-maven-plugin. One of it's >> goals is 'update-file-header'. >> And, it actually has an integration-test executed by maven-invoker-plugin >> but it's on a sample project. >> What if I wanted to run the update-file-header on the license-maven-plugin >> itself? How? >> >> One straight way would be introduce another profile to configure the >> plugin >> to run on itself, but is this a >> good practice on Maven plugin development? >> >> Thanks, >> Behrooz >> >> >> >> [1]: http://maven.apache.org/plugins/maven-invoker-plugin/ >> [2]: >> >> https://github.com/mojohaus/license-maven-plugin/tree/master/src/it/update-file-header-test-mojo >> >> > > --------------------------------------------------------------------- > To unsubscribe, e-mail: dev-unsubscr...@maven.apache.org > For additional commands, e-mail: dev-h...@maven.apache.org > > -- -- Behrooz Nobakht