Here is why:
It (my plugin) will be be run in multiple phases, and needs to log:
- what pom is being made
- what phase it is in
- the time my plugin is run
There are parts of our build that can take a very long time to run if
certain problems occur.
By monitoring a log of when some various points are reached, I can tell if
it is worth stopping the the build then doing some housekeeping so it will
run much faster, and then restarting it after the housekeeping.
Perhaps I can set values to be passed into it based on what phase it is
being used, but then that makes it more work to set up.
Jason van Zyl-2 wrote:
>
>
> On 30 Jul 07, at 1:18 PM 30 Jul 07, John Petritis wrote:
>
>>
>> I need to be able to get the phase my plugin is run in.
>
> Why?
>
> There is no way to get the phase a plugin is running in as you
> generally declare that from the outside i.e. a workflow that the mojo
> takes part in.
>
>> I will probably make it run in multiple phases.
>> I would prefer to get the phase from an @parameter expression="${???}"
>> But I cannot figure out what variable name to use in it.
>>
>> (I am basically trying to make a logger that tracks when maven gets to
>> various phases of various projects)
>>
>> Thank You
>> --
>> View this message in context: http://www.nabble.com/Plugin-
>> development%3A-how-to-get-the-phase-tf4171209s177.html#a11866794
>> Sent from the Maven Developers mailing list archive at Nabble.com.
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: [EMAIL PROTECTED]
>> For additional commands, e-mail: [EMAIL PROTECTED]
>>
>
> Thanks,
>
> Jason
>
> ----------------------------------------------------------
> Jason van Zyl
> Founder and PMC Chair, Apache Maven
> jason at sonatype dot com
> ----------------------------------------------------------
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
>
--
View this message in context:
http://www.nabble.com/Plugin-development%3A-how-to-get-the-phase-tf4171209s177.html#a11881846
Sent from the Maven Developers mailing list archive at Nabble.com.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]