kgf3JfUtW
kgf3JfUtW

Reputation: 14918

Maven: Is clean a lifecycle or a phase?

I understand a lifecycle contains phases, and a phase may have plugin goals bound to it.

But is clean a lifecycle or phase?

Introduction to the Build Lifecycle seems to suggest clean is both a lifecycle and a phase:

There are three built-in build lifecycles: default, clean and site.

...

The clean and package arguments are build phases, while the dependency:copy-dependencies is a goal (of a plugin). mvn clean dependency:copy-dependencies package

Upvotes: 6

Views: 1039

Answers (1)

Boris
Boris

Reputation: 24443

Clean Lifecycle contains 3 build phases:

pre-clean  

clean

post-clean

So a pedantic answer (taking into account the question formatting) would be:

clean is a build phase of Clean Lifecycle


By the way there is also a 3rd meaning, goal-to-build-phase binding:

Clean Lifecycle Binding clean

Upvotes: 5

Related Questions