From be3687005f421be3c2a7532b0867061a3ff7dfa5 Mon Sep 17 00:00:00 2001 From: Sylwester Lachiewicz Date: Sun, 18 Sep 2022 10:58:18 +0200 Subject: [PATCH] (doc) remove unused and deprecated Mojo annotation requiresProject. Also requiresProject = true is default --- src/main/java/org/codehaus/mojo/versions/CommitMojo.java | 2 +- .../org/codehaus/mojo/versions/CompareDependenciesMojo.java | 2 +- .../codehaus/mojo/versions/DisplayDependencyUpdatesMojo.java | 3 +-- .../org/codehaus/mojo/versions/DisplayParentUpdatesMojo.java | 2 +- .../org/codehaus/mojo/versions/DisplayPluginUpdatesMojo.java | 2 +- .../codehaus/mojo/versions/DisplayPropertyUpdatesMojo.java | 2 +- .../java/org/codehaus/mojo/versions/ForceReleasesMojo.java | 2 +- .../java/org/codehaus/mojo/versions/LockSnapshotsMojo.java | 2 +- .../org/codehaus/mojo/versions/PropertyUpdatesReport.java | 2 +- .../java/org/codehaus/mojo/versions/ResolveRangesMojo.java | 2 +- src/main/java/org/codehaus/mojo/versions/RevertMojo.java | 2 +- src/main/java/org/codehaus/mojo/versions/SetMojo.java | 2 +- .../java/org/codehaus/mojo/versions/SetPropertyMojo.java | 2 +- src/main/java/org/codehaus/mojo/versions/SetScmTagMojo.java | 2 +- .../java/org/codehaus/mojo/versions/UnlockSnapshotsMojo.java | 5 +---- .../org/codehaus/mojo/versions/UpdateChildModulesMojo.java | 2 +- .../java/org/codehaus/mojo/versions/UpdateParentMojo.java | 5 +---- .../org/codehaus/mojo/versions/UpdatePropertiesMojo.java | 5 +---- .../java/org/codehaus/mojo/versions/UpdatePropertyMojo.java | 2 +- .../java/org/codehaus/mojo/versions/UseDepVersionMojo.java | 4 +--- .../org/codehaus/mojo/versions/UseLatestReleasesMojo.java | 2 +- .../org/codehaus/mojo/versions/UseLatestSnapshotsMojo.java | 2 +- .../org/codehaus/mojo/versions/UseLatestVersionsMojo.java | 2 +- .../java/org/codehaus/mojo/versions/UseNextReleasesMojo.java | 2 +- .../org/codehaus/mojo/versions/UseNextSnapshotsMojo.java | 2 +- .../java/org/codehaus/mojo/versions/UseNextVersionsMojo.java | 2 +- src/main/java/org/codehaus/mojo/versions/UseReactorMojo.java | 2 +- .../java/org/codehaus/mojo/versions/UseReleasesMojo.java | 2 +- 28 files changed, 28 insertions(+), 40 deletions(-) diff --git a/src/main/java/org/codehaus/mojo/versions/CommitMojo.java b/src/main/java/org/codehaus/mojo/versions/CommitMojo.java index 3a715cff70..b1bf396613 100644 --- a/src/main/java/org/codehaus/mojo/versions/CommitMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/CommitMojo.java @@ -36,7 +36,7 @@ * @author Stephen Connolly * @since 1.0-alpha-3 */ -@Mojo( name = "commit", requiresProject = true, requiresDirectInvocation = true, threadSafe = true ) +@Mojo( name = "commit", threadSafe = true ) public class CommitMojo extends AbstractMojo { diff --git a/src/main/java/org/codehaus/mojo/versions/CompareDependenciesMojo.java b/src/main/java/org/codehaus/mojo/versions/CompareDependenciesMojo.java index 0ba886afdc..8e802ae118 100644 --- a/src/main/java/org/codehaus/mojo/versions/CompareDependenciesMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/CompareDependenciesMojo.java @@ -57,7 +57,7 @@ * @author Paul Gier * @since 1.3 */ -@Mojo( name = "compare-dependencies", requiresProject = true, requiresDirectInvocation = true, threadSafe = true ) +@Mojo( name = "compare-dependencies", threadSafe = true ) public class CompareDependenciesMojo extends AbstractVersionsDependencyUpdaterMojo { diff --git a/src/main/java/org/codehaus/mojo/versions/DisplayDependencyUpdatesMojo.java b/src/main/java/org/codehaus/mojo/versions/DisplayDependencyUpdatesMojo.java index 8f515b70fc..bf3a2ac185 100644 --- a/src/main/java/org/codehaus/mojo/versions/DisplayDependencyUpdatesMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/DisplayDependencyUpdatesMojo.java @@ -72,8 +72,7 @@ * @author Stephen Connolly * @since 1.0-alpha-1 */ -@Mojo( name = "display-dependency-updates", requiresProject = true, requiresDirectInvocation = false, - threadSafe = true ) +@Mojo( name = "display-dependency-updates", threadSafe = true ) public class DisplayDependencyUpdatesMojo extends AbstractVersionsDisplayMojo { diff --git a/src/main/java/org/codehaus/mojo/versions/DisplayParentUpdatesMojo.java b/src/main/java/org/codehaus/mojo/versions/DisplayParentUpdatesMojo.java index 03363e5dbb..066aab7e2b 100644 --- a/src/main/java/org/codehaus/mojo/versions/DisplayParentUpdatesMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/DisplayParentUpdatesMojo.java @@ -44,7 +44,7 @@ * @author Stephen Connolly * @since 2.2 */ -@Mojo( name = "display-parent-updates", requiresProject = true, requiresDirectInvocation = true, threadSafe = true ) +@Mojo( name = "display-parent-updates", threadSafe = true ) public class DisplayParentUpdatesMojo extends AbstractVersionsDisplayMojo { diff --git a/src/main/java/org/codehaus/mojo/versions/DisplayPluginUpdatesMojo.java b/src/main/java/org/codehaus/mojo/versions/DisplayPluginUpdatesMojo.java index 668fa3cef6..09f035fe29 100644 --- a/src/main/java/org/codehaus/mojo/versions/DisplayPluginUpdatesMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/DisplayPluginUpdatesMojo.java @@ -109,7 +109,7 @@ * @author Stephen Connolly * @since 1.0-alpha-1 */ -@Mojo( name = "display-plugin-updates", requiresProject = true, requiresDirectInvocation = false, threadSafe = true ) +@Mojo( name = "display-plugin-updates", threadSafe = true ) public class DisplayPluginUpdatesMojo extends AbstractVersionsDisplayMojo { diff --git a/src/main/java/org/codehaus/mojo/versions/DisplayPropertyUpdatesMojo.java b/src/main/java/org/codehaus/mojo/versions/DisplayPropertyUpdatesMojo.java index 46d29094fd..238077de9b 100644 --- a/src/main/java/org/codehaus/mojo/versions/DisplayPropertyUpdatesMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/DisplayPropertyUpdatesMojo.java @@ -49,7 +49,7 @@ * @author Stephen Connolly * @since 1.0-beta-1 */ -@Mojo( name = "display-property-updates", requiresProject = true, requiresDirectInvocation = true, threadSafe = true ) +@Mojo( name = "display-property-updates", threadSafe = true ) public class DisplayPropertyUpdatesMojo extends AbstractVersionsDisplayMojo { diff --git a/src/main/java/org/codehaus/mojo/versions/ForceReleasesMojo.java b/src/main/java/org/codehaus/mojo/versions/ForceReleasesMojo.java index 566cf6bd82..56c9812643 100644 --- a/src/main/java/org/codehaus/mojo/versions/ForceReleasesMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/ForceReleasesMojo.java @@ -48,7 +48,7 @@ * @author Stephen Connolly * @since 2.2 */ -@Mojo( name = "force-releases", requiresProject = true, requiresDirectInvocation = true, threadSafe = true ) +@Mojo( name = "force-releases", threadSafe = true ) public class ForceReleasesMojo extends AbstractVersionsDependencyUpdaterMojo { diff --git a/src/main/java/org/codehaus/mojo/versions/LockSnapshotsMojo.java b/src/main/java/org/codehaus/mojo/versions/LockSnapshotsMojo.java index 5e88809cee..9e17a35942 100644 --- a/src/main/java/org/codehaus/mojo/versions/LockSnapshotsMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/LockSnapshotsMojo.java @@ -49,7 +49,7 @@ * @author Paul Gier * @since 1.0-alpha-3 */ -@Mojo( name = "lock-snapshots", requiresProject = true, requiresDirectInvocation = true, threadSafe = true ) +@Mojo( name = "lock-snapshots", threadSafe = true ) public class LockSnapshotsMojo extends AbstractVersionsDependencyUpdaterMojo { diff --git a/src/main/java/org/codehaus/mojo/versions/PropertyUpdatesReport.java b/src/main/java/org/codehaus/mojo/versions/PropertyUpdatesReport.java index b3fb648101..4093b70c3e 100644 --- a/src/main/java/org/codehaus/mojo/versions/PropertyUpdatesReport.java +++ b/src/main/java/org/codehaus/mojo/versions/PropertyUpdatesReport.java @@ -46,7 +46,7 @@ * @author Stephen Connolly * @since 1.0-beta-1 */ -@Mojo( name = "property-updates-report", requiresProject = true, requiresDependencyResolution = ResolutionScope.RUNTIME, +@Mojo( name = "property-updates-report", requiresDependencyResolution = ResolutionScope.RUNTIME, threadSafe = true ) public class PropertyUpdatesReport extends AbstractVersionsReport diff --git a/src/main/java/org/codehaus/mojo/versions/ResolveRangesMojo.java b/src/main/java/org/codehaus/mojo/versions/ResolveRangesMojo.java index 9e1eaa7766..14bf5c73b5 100644 --- a/src/main/java/org/codehaus/mojo/versions/ResolveRangesMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/ResolveRangesMojo.java @@ -54,7 +54,7 @@ * @author Paul Gier * @since 1.0-alpha-3 */ -@Mojo( name = "resolve-ranges", requiresProject = true, requiresDirectInvocation = true, threadSafe = true ) +@Mojo( name = "resolve-ranges", threadSafe = true ) public class ResolveRangesMojo extends AbstractVersionsDependencyUpdaterMojo { diff --git a/src/main/java/org/codehaus/mojo/versions/RevertMojo.java b/src/main/java/org/codehaus/mojo/versions/RevertMojo.java index dd5f289bd6..a85092f420 100644 --- a/src/main/java/org/codehaus/mojo/versions/RevertMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/RevertMojo.java @@ -36,7 +36,7 @@ * @author Stephen Connolly * @since 1.0-alpha-3 */ -@Mojo( name = "revert", requiresProject = true, requiresDirectInvocation = true, threadSafe = true ) +@Mojo( name = "revert", threadSafe = true ) public class RevertMojo extends AbstractMojo { diff --git a/src/main/java/org/codehaus/mojo/versions/SetMojo.java b/src/main/java/org/codehaus/mojo/versions/SetMojo.java index d925175494..9fee67c5d2 100644 --- a/src/main/java/org/codehaus/mojo/versions/SetMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/SetMojo.java @@ -72,7 +72,7 @@ * @author Stephen Connolly * @since 1.0-beta-1 */ -@Mojo( name = "set", requiresProject = true, requiresDirectInvocation = true, aggregator = true, threadSafe = true ) +@Mojo( name = "set", aggregator = true, threadSafe = true ) public class SetMojo extends AbstractVersionsUpdaterMojo { diff --git a/src/main/java/org/codehaus/mojo/versions/SetPropertyMojo.java b/src/main/java/org/codehaus/mojo/versions/SetPropertyMojo.java index 18ac4743e4..6ab5915347 100644 --- a/src/main/java/org/codehaus/mojo/versions/SetPropertyMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/SetPropertyMojo.java @@ -52,7 +52,7 @@ * @author Karl Heinz Marbaise * @since 2.5 */ -@Mojo( name = "set-property", requiresProject = true, requiresDirectInvocation = true, threadSafe = true ) +@Mojo( name = "set-property", threadSafe = true ) public class SetPropertyMojo extends AbstractVersionsUpdaterMojo { diff --git a/src/main/java/org/codehaus/mojo/versions/SetScmTagMojo.java b/src/main/java/org/codehaus/mojo/versions/SetScmTagMojo.java index ca54ef0136..addeab5dce 100644 --- a/src/main/java/org/codehaus/mojo/versions/SetScmTagMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/SetScmTagMojo.java @@ -30,7 +30,7 @@ * @author Anton Johansson * @since 2.5 */ -@Mojo( name = "set-scm-tag", requiresDirectInvocation = true, aggregator = true, threadSafe = true ) +@Mojo( name = "set-scm-tag", aggregator = true, threadSafe = true ) public class SetScmTagMojo extends AbstractVersionsUpdaterMojo { diff --git a/src/main/java/org/codehaus/mojo/versions/UnlockSnapshotsMojo.java b/src/main/java/org/codehaus/mojo/versions/UnlockSnapshotsMojo.java index fe4c1ce01f..d338a53d34 100644 --- a/src/main/java/org/codehaus/mojo/versions/UnlockSnapshotsMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/UnlockSnapshotsMojo.java @@ -49,10 +49,7 @@ * @author Paul Gier * @since 1.0-alpha-3 */ -@Mojo( name = "unlock-snapshots", - requiresProject = true, - requiresDirectInvocation = true, - threadSafe = true ) +@Mojo( name = "unlock-snapshots", threadSafe = true ) public class UnlockSnapshotsMojo extends AbstractVersionsDependencyUpdaterMojo { diff --git a/src/main/java/org/codehaus/mojo/versions/UpdateChildModulesMojo.java b/src/main/java/org/codehaus/mojo/versions/UpdateChildModulesMojo.java index 2de5878a03..be50bbeb08 100644 --- a/src/main/java/org/codehaus/mojo/versions/UpdateChildModulesMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/UpdateChildModulesMojo.java @@ -49,7 +49,7 @@ * @author Stephen Connolly * @since 1.0-alpha-2 */ -@Mojo( name = "update-child-modules", requiresProject = true, requiresDirectInvocation = true, aggregator = true, +@Mojo( name = "update-child-modules", aggregator = true, threadSafe = true ) public class UpdateChildModulesMojo extends AbstractVersionsUpdaterMojo diff --git a/src/main/java/org/codehaus/mojo/versions/UpdateParentMojo.java b/src/main/java/org/codehaus/mojo/versions/UpdateParentMojo.java index 2c3add8798..b3ee61b8ab 100644 --- a/src/main/java/org/codehaus/mojo/versions/UpdateParentMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/UpdateParentMojo.java @@ -49,10 +49,7 @@ * @author Stephen Connolly * @since 1.0-alpha-1 */ -@Mojo( name = "update-parent", - requiresProject = true, - requiresDirectInvocation = true, - threadSafe = true ) +@Mojo( name = "update-parent", threadSafe = true ) public class UpdateParentMojo extends AbstractVersionsUpdaterMojo { diff --git a/src/main/java/org/codehaus/mojo/versions/UpdatePropertiesMojo.java b/src/main/java/org/codehaus/mojo/versions/UpdatePropertiesMojo.java index c9b3ab9781..910eff7439 100644 --- a/src/main/java/org/codehaus/mojo/versions/UpdatePropertiesMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/UpdatePropertiesMojo.java @@ -46,10 +46,7 @@ * @author Stephen Connolly * @since 1.0-alpha-1 */ -@Mojo( name = "update-properties", - requiresProject = true, - requiresDirectInvocation = true, - threadSafe = true ) +@Mojo( name = "update-properties", threadSafe = true ) public class UpdatePropertiesMojo extends AbstractVersionsDependencyUpdaterMojo { diff --git a/src/main/java/org/codehaus/mojo/versions/UpdatePropertyMojo.java b/src/main/java/org/codehaus/mojo/versions/UpdatePropertyMojo.java index ca427f9418..0101e5ebdc 100644 --- a/src/main/java/org/codehaus/mojo/versions/UpdatePropertyMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/UpdatePropertyMojo.java @@ -46,7 +46,7 @@ * @author Eric Pabst * @since 1.3 */ -@Mojo( name = "update-property", requiresProject = true, requiresDirectInvocation = true, threadSafe = true ) +@Mojo( name = "update-property", threadSafe = true ) public class UpdatePropertyMojo extends AbstractVersionsUpdaterMojo { diff --git a/src/main/java/org/codehaus/mojo/versions/UseDepVersionMojo.java b/src/main/java/org/codehaus/mojo/versions/UseDepVersionMojo.java index f9426c56bd..ccd389e0ad 100644 --- a/src/main/java/org/codehaus/mojo/versions/UseDepVersionMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/UseDepVersionMojo.java @@ -48,9 +48,7 @@ * @author Dan Arcari * @since 2.3 */ -@Mojo( name = "use-dep-version", - requiresProject = true, - threadSafe = true ) +@Mojo( name = "use-dep-version", threadSafe = true ) public class UseDepVersionMojo extends AbstractVersionsDependencyUpdaterMojo { diff --git a/src/main/java/org/codehaus/mojo/versions/UseLatestReleasesMojo.java b/src/main/java/org/codehaus/mojo/versions/UseLatestReleasesMojo.java index e61fdfa103..c48197b2c6 100644 --- a/src/main/java/org/codehaus/mojo/versions/UseLatestReleasesMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/UseLatestReleasesMojo.java @@ -60,7 +60,7 @@ * @author Stephen Connolly * @since 1.0-alpha-3 */ -@Mojo( name = "use-latest-releases", requiresProject = true, requiresDirectInvocation = true, threadSafe = true ) +@Mojo( name = "use-latest-releases", threadSafe = true ) public class UseLatestReleasesMojo extends AbstractVersionsDependencyUpdaterMojo { diff --git a/src/main/java/org/codehaus/mojo/versions/UseLatestSnapshotsMojo.java b/src/main/java/org/codehaus/mojo/versions/UseLatestSnapshotsMojo.java index 7d65fe0349..fb8cea2d7f 100644 --- a/src/main/java/org/codehaus/mojo/versions/UseLatestSnapshotsMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/UseLatestSnapshotsMojo.java @@ -59,7 +59,7 @@ * @author Stephen Connolly * @since 1.0-beta-1 */ -@Mojo( name = "use-latest-snapshots", requiresProject = true, requiresDirectInvocation = true, threadSafe = true ) +@Mojo( name = "use-latest-snapshots", threadSafe = true ) public class UseLatestSnapshotsMojo extends AbstractVersionsDependencyUpdaterMojo { diff --git a/src/main/java/org/codehaus/mojo/versions/UseLatestVersionsMojo.java b/src/main/java/org/codehaus/mojo/versions/UseLatestVersionsMojo.java index aafeafcf6c..e93b7d5a3c 100644 --- a/src/main/java/org/codehaus/mojo/versions/UseLatestVersionsMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/UseLatestVersionsMojo.java @@ -55,7 +55,7 @@ * @author Stephen Connolly * @since 1.0-alpha-3 */ -@Mojo( name = "use-latest-versions", requiresProject = true, requiresDirectInvocation = true, threadSafe = true ) +@Mojo( name = "use-latest-versions", threadSafe = true ) public class UseLatestVersionsMojo extends AbstractVersionsDependencyUpdaterMojo { diff --git a/src/main/java/org/codehaus/mojo/versions/UseNextReleasesMojo.java b/src/main/java/org/codehaus/mojo/versions/UseNextReleasesMojo.java index c58bd1e6ae..149cc23f0f 100644 --- a/src/main/java/org/codehaus/mojo/versions/UseNextReleasesMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/UseNextReleasesMojo.java @@ -48,7 +48,7 @@ * @author Stephen Connolly * @since 1.0-alpha-3 */ -@Mojo( name = "use-next-releases", requiresProject = true, requiresDirectInvocation = true, threadSafe = true ) +@Mojo( name = "use-next-releases", threadSafe = true ) public class UseNextReleasesMojo extends AbstractVersionsDependencyUpdaterMojo { diff --git a/src/main/java/org/codehaus/mojo/versions/UseNextSnapshotsMojo.java b/src/main/java/org/codehaus/mojo/versions/UseNextSnapshotsMojo.java index 255db131e0..be11af6fa4 100644 --- a/src/main/java/org/codehaus/mojo/versions/UseNextSnapshotsMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/UseNextSnapshotsMojo.java @@ -54,7 +54,7 @@ * @author Stephen Connolly * @since 1.0-beta-1 */ -@Mojo( name = "use-next-snapshots", requiresProject = true, requiresDirectInvocation = true, threadSafe = true ) +@Mojo( name = "use-next-snapshots", threadSafe = true ) public class UseNextSnapshotsMojo extends AbstractVersionsDependencyUpdaterMojo { diff --git a/src/main/java/org/codehaus/mojo/versions/UseNextVersionsMojo.java b/src/main/java/org/codehaus/mojo/versions/UseNextVersionsMojo.java index 6b46fd8e61..ba0223cf98 100644 --- a/src/main/java/org/codehaus/mojo/versions/UseNextVersionsMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/UseNextVersionsMojo.java @@ -46,7 +46,7 @@ * @author Stephen Connolly * @since 1.0-alpha-3 */ -@Mojo( name = "use-next-versions", requiresProject = true, requiresDirectInvocation = true, threadSafe = true ) +@Mojo( name = "use-next-versions", threadSafe = true ) public class UseNextVersionsMojo extends AbstractVersionsDependencyUpdaterMojo { diff --git a/src/main/java/org/codehaus/mojo/versions/UseReactorMojo.java b/src/main/java/org/codehaus/mojo/versions/UseReactorMojo.java index e0ebc85ca3..467a2d747a 100644 --- a/src/main/java/org/codehaus/mojo/versions/UseReactorMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/UseReactorMojo.java @@ -46,7 +46,7 @@ * @author Stephen Connolly * @since 2.2 */ -@Mojo( name = "use-reactor", requiresProject = true, requiresDirectInvocation = true, threadSafe = true ) +@Mojo( name = "use-reactor", threadSafe = true ) public class UseReactorMojo extends AbstractVersionsDependencyUpdaterMojo { diff --git a/src/main/java/org/codehaus/mojo/versions/UseReleasesMojo.java b/src/main/java/org/codehaus/mojo/versions/UseReleasesMojo.java index 514472d64c..6e71ff0aaa 100644 --- a/src/main/java/org/codehaus/mojo/versions/UseReleasesMojo.java +++ b/src/main/java/org/codehaus/mojo/versions/UseReleasesMojo.java @@ -52,7 +52,7 @@ * @author Stephen Connolly * @since 1.0-alpha-3 */ -@Mojo( name = "use-releases", requiresProject = true, requiresDirectInvocation = true, threadSafe = true ) +@Mojo( name = "use-releases", threadSafe = true ) public class UseReleasesMojo extends AbstractVersionsDependencyUpdaterMojo {