Resolves #837: Add includeParent (default true) to UpdatePropertiesMojo#838
Conversation
a742a88 to
3689b13
Compare
|
@slawekjaranowski please review Spotted a minor bug: change recorder would always output changes, even if they did not occur in the POM that was being processed. Fixed. This resolves #837 |
35372a8 to
67035ad
Compare
|
Added the same to |
67035ad to
b324f5c
Compare
|
And abstracted a common base for the two mojos. |
|
Tried to resolve conflicts using GitHub 🤦 |
5292c53 to
122d4f7
Compare
122d4f7 to
c0a951d
Compare
|
We set such parameters to Should be here default as |
No. With
So, it can only be treated as a speedup if one knows what they're doing. It will sometimes render the results wrong. So, it must be By the way, should I remove this? getLog().debug( "Using Maven 2.0.10+ strategy to determine lifecycle defined plugins" );
try
{
Method getLifecycles = LifecycleExecutor.class.getMethod( "getLifecycles" );
List<Lifecycle> lifecycles = (List) getLifecycles.invoke( lifecycleExecutor, new Object[0] );
// lookup the bindings for all the passed in phases
return Arrays.stream( thePhases.split( "," ) )
.filter( StringUtils::isNotEmpty )
.map( phase -> getLifecycleForPhase( lifecycles, phase ) )
.filter( Objects::nonNull )
.collect( HashSet::new,
( s, l ) -> s.addAll( getAllPlugins( project, l ) ),
Set::addAll ); |
|
Maven 2.x code should be remove, can be done in separate PR. |
I'll do that in another PR then |
Upon request of a user in #793, adding
includeParent(trueby default) toUpdatePropertiesMojo.Setting it to
falsewill speed up execution to a great extend without sacrificing accuracy in most cases. However, if the POM redefines properties used in parent POMs, dependencies bound to those properties will not be discovered, so the plugin will not redefine those properties. Therefore the default value istrue.