“Project does not define required minimum version of Maven” with versions-maven-plugin 2.7
I'm facing the following error executing mvn versions:display-plugin-updates
. Basing on this discussion, that was fixed in 2.6, but I'm using 2.7 (tried with 2.6 but with no success).
[ERROR] Project does not define required minimum version of Maven.
[ERROR] Update the pom.xml to contain maven-enforcer-plugin to
[ERROR] force the Maven version which is needed to build this project.
[ERROR] See https://maven.apache.org/enforcer/enforcer-rules/requireMavenVersion.html
[ERROR] Using the minimum version of Maven: 3.0.5
Here's my <pluginManager>
plugins:
<pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-enforcer-plugin</artifactId>
<version>3.0.0-M2</version>
<executions>
<execution>
<id>enforce-versions</id>
<goals>
<goal>enforce</goal>
</goals>
<configuration>
<rules>
<requireMavenVersion>
<version>3.5.4</version>
</requireMavenVersion>
</rules>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>versions-maven-plugin</artifactId>
<version>2.7</version>
<configuration>
<generateBackupPoms>false</generateBackupPoms>
</configuration>
</plugin>
</plugins>
</pluginManagement>
maven maven-3 maven-enforcer-plugin versions-maven-plugin
|
show 3 more comments
I'm facing the following error executing mvn versions:display-plugin-updates
. Basing on this discussion, that was fixed in 2.6, but I'm using 2.7 (tried with 2.6 but with no success).
[ERROR] Project does not define required minimum version of Maven.
[ERROR] Update the pom.xml to contain maven-enforcer-plugin to
[ERROR] force the Maven version which is needed to build this project.
[ERROR] See https://maven.apache.org/enforcer/enforcer-rules/requireMavenVersion.html
[ERROR] Using the minimum version of Maven: 3.0.5
Here's my <pluginManager>
plugins:
<pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-enforcer-plugin</artifactId>
<version>3.0.0-M2</version>
<executions>
<execution>
<id>enforce-versions</id>
<goals>
<goal>enforce</goal>
</goals>
<configuration>
<rules>
<requireMavenVersion>
<version>3.5.4</version>
</requireMavenVersion>
</rules>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>versions-maven-plugin</artifactId>
<version>2.7</version>
<configuration>
<generateBackupPoms>false</generateBackupPoms>
</configuration>
</plugin>
</plugins>
</pluginManagement>
maven maven-3 maven-enforcer-plugin versions-maven-plugin
plugins
element is not closed.
– Ortomala Lokni
Nov 12 '18 at 19:41
Have you declared the plugins in the build->plugins section of your pom?
– gjoranv
Nov 12 '18 at 22:47
Thanks @OrtomalaLokni, seems like it was lost while creating a post. It's closed in my pom
– sys463
Nov 13 '18 at 10:51
@gjoranv, no I have not. Does it make any sense, since I've declared in<pluginManagement>
?
– sys463
Nov 13 '18 at 10:53
It's easy to verify. Either, move the 'plugins' block directly under 'build' instead of 'pluginManagement'. Or just add the plugins inside 'build' without any version or config, which will then be "inherited" from pluginManagement.
– gjoranv
Nov 13 '18 at 11:23
|
show 3 more comments
I'm facing the following error executing mvn versions:display-plugin-updates
. Basing on this discussion, that was fixed in 2.6, but I'm using 2.7 (tried with 2.6 but with no success).
[ERROR] Project does not define required minimum version of Maven.
[ERROR] Update the pom.xml to contain maven-enforcer-plugin to
[ERROR] force the Maven version which is needed to build this project.
[ERROR] See https://maven.apache.org/enforcer/enforcer-rules/requireMavenVersion.html
[ERROR] Using the minimum version of Maven: 3.0.5
Here's my <pluginManager>
plugins:
<pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-enforcer-plugin</artifactId>
<version>3.0.0-M2</version>
<executions>
<execution>
<id>enforce-versions</id>
<goals>
<goal>enforce</goal>
</goals>
<configuration>
<rules>
<requireMavenVersion>
<version>3.5.4</version>
</requireMavenVersion>
</rules>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>versions-maven-plugin</artifactId>
<version>2.7</version>
<configuration>
<generateBackupPoms>false</generateBackupPoms>
</configuration>
</plugin>
</plugins>
</pluginManagement>
maven maven-3 maven-enforcer-plugin versions-maven-plugin
I'm facing the following error executing mvn versions:display-plugin-updates
. Basing on this discussion, that was fixed in 2.6, but I'm using 2.7 (tried with 2.6 but with no success).
[ERROR] Project does not define required minimum version of Maven.
[ERROR] Update the pom.xml to contain maven-enforcer-plugin to
[ERROR] force the Maven version which is needed to build this project.
[ERROR] See https://maven.apache.org/enforcer/enforcer-rules/requireMavenVersion.html
[ERROR] Using the minimum version of Maven: 3.0.5
Here's my <pluginManager>
plugins:
<pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-enforcer-plugin</artifactId>
<version>3.0.0-M2</version>
<executions>
<execution>
<id>enforce-versions</id>
<goals>
<goal>enforce</goal>
</goals>
<configuration>
<rules>
<requireMavenVersion>
<version>3.5.4</version>
</requireMavenVersion>
</rules>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>versions-maven-plugin</artifactId>
<version>2.7</version>
<configuration>
<generateBackupPoms>false</generateBackupPoms>
</configuration>
</plugin>
</plugins>
</pluginManagement>
maven maven-3 maven-enforcer-plugin versions-maven-plugin
maven maven-3 maven-enforcer-plugin versions-maven-plugin
edited Nov 13 '18 at 10:50
sys463
asked Nov 12 '18 at 18:13
sys463sys463
398
398
plugins
element is not closed.
– Ortomala Lokni
Nov 12 '18 at 19:41
Have you declared the plugins in the build->plugins section of your pom?
– gjoranv
Nov 12 '18 at 22:47
Thanks @OrtomalaLokni, seems like it was lost while creating a post. It's closed in my pom
– sys463
Nov 13 '18 at 10:51
@gjoranv, no I have not. Does it make any sense, since I've declared in<pluginManagement>
?
– sys463
Nov 13 '18 at 10:53
It's easy to verify. Either, move the 'plugins' block directly under 'build' instead of 'pluginManagement'. Or just add the plugins inside 'build' without any version or config, which will then be "inherited" from pluginManagement.
– gjoranv
Nov 13 '18 at 11:23
|
show 3 more comments
plugins
element is not closed.
– Ortomala Lokni
Nov 12 '18 at 19:41
Have you declared the plugins in the build->plugins section of your pom?
– gjoranv
Nov 12 '18 at 22:47
Thanks @OrtomalaLokni, seems like it was lost while creating a post. It's closed in my pom
– sys463
Nov 13 '18 at 10:51
@gjoranv, no I have not. Does it make any sense, since I've declared in<pluginManagement>
?
– sys463
Nov 13 '18 at 10:53
It's easy to verify. Either, move the 'plugins' block directly under 'build' instead of 'pluginManagement'. Or just add the plugins inside 'build' without any version or config, which will then be "inherited" from pluginManagement.
– gjoranv
Nov 13 '18 at 11:23
plugins
element is not closed.– Ortomala Lokni
Nov 12 '18 at 19:41
plugins
element is not closed.– Ortomala Lokni
Nov 12 '18 at 19:41
Have you declared the plugins in the build->plugins section of your pom?
– gjoranv
Nov 12 '18 at 22:47
Have you declared the plugins in the build->plugins section of your pom?
– gjoranv
Nov 12 '18 at 22:47
Thanks @OrtomalaLokni, seems like it was lost while creating a post. It's closed in my pom
– sys463
Nov 13 '18 at 10:51
Thanks @OrtomalaLokni, seems like it was lost while creating a post. It's closed in my pom
– sys463
Nov 13 '18 at 10:51
@gjoranv, no I have not. Does it make any sense, since I've declared in
<pluginManagement>
?– sys463
Nov 13 '18 at 10:53
@gjoranv, no I have not. Does it make any sense, since I've declared in
<pluginManagement>
?– sys463
Nov 13 '18 at 10:53
It's easy to verify. Either, move the 'plugins' block directly under 'build' instead of 'pluginManagement'. Or just add the plugins inside 'build' without any version or config, which will then be "inherited" from pluginManagement.
– gjoranv
Nov 13 '18 at 11:23
It's easy to verify. Either, move the 'plugins' block directly under 'build' instead of 'pluginManagement'. Or just add the plugins inside 'build' without any version or config, which will then be "inherited" from pluginManagement.
– gjoranv
Nov 13 '18 at 11:23
|
show 3 more comments
1 Answer
1
active
oldest
votes
Even if you have pluginManagement
for a given plugin, you still need to declare the plugin in your pom's build
->plugins
section for the configuration to take effect. While some plugins, e.g. maven-compiler-plugin
are added to the project by default, this is clearly not the case for maven-enforcer-plugin
(as shown by your experiment).
I'm not sure if there is a list of plugins that don't need to be explicitly added, but I assume it's the most common ones like maven-surefire-plugin and maven-clean-plugin.
add a comment |
Your Answer
StackExchange.ifUsing("editor", function () {
StackExchange.using("externalEditor", function () {
StackExchange.using("snippets", function () {
StackExchange.snippets.init();
});
});
}, "code-snippets");
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "1"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53267857%2fproject-does-not-define-required-minimum-version-of-maven-with-versions-maven%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
1 Answer
1
active
oldest
votes
1 Answer
1
active
oldest
votes
active
oldest
votes
active
oldest
votes
Even if you have pluginManagement
for a given plugin, you still need to declare the plugin in your pom's build
->plugins
section for the configuration to take effect. While some plugins, e.g. maven-compiler-plugin
are added to the project by default, this is clearly not the case for maven-enforcer-plugin
(as shown by your experiment).
I'm not sure if there is a list of plugins that don't need to be explicitly added, but I assume it's the most common ones like maven-surefire-plugin and maven-clean-plugin.
add a comment |
Even if you have pluginManagement
for a given plugin, you still need to declare the plugin in your pom's build
->plugins
section for the configuration to take effect. While some plugins, e.g. maven-compiler-plugin
are added to the project by default, this is clearly not the case for maven-enforcer-plugin
(as shown by your experiment).
I'm not sure if there is a list of plugins that don't need to be explicitly added, but I assume it's the most common ones like maven-surefire-plugin and maven-clean-plugin.
add a comment |
Even if you have pluginManagement
for a given plugin, you still need to declare the plugin in your pom's build
->plugins
section for the configuration to take effect. While some plugins, e.g. maven-compiler-plugin
are added to the project by default, this is clearly not the case for maven-enforcer-plugin
(as shown by your experiment).
I'm not sure if there is a list of plugins that don't need to be explicitly added, but I assume it's the most common ones like maven-surefire-plugin and maven-clean-plugin.
Even if you have pluginManagement
for a given plugin, you still need to declare the plugin in your pom's build
->plugins
section for the configuration to take effect. While some plugins, e.g. maven-compiler-plugin
are added to the project by default, this is clearly not the case for maven-enforcer-plugin
(as shown by your experiment).
I'm not sure if there is a list of plugins that don't need to be explicitly added, but I assume it's the most common ones like maven-surefire-plugin and maven-clean-plugin.
answered Nov 13 '18 at 15:58
gjoranvgjoranv
1,4741518
1,4741518
add a comment |
add a comment |
Thanks for contributing an answer to Stack Overflow!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53267857%2fproject-does-not-define-required-minimum-version-of-maven-with-versions-maven%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
plugins
element is not closed.– Ortomala Lokni
Nov 12 '18 at 19:41
Have you declared the plugins in the build->plugins section of your pom?
– gjoranv
Nov 12 '18 at 22:47
Thanks @OrtomalaLokni, seems like it was lost while creating a post. It's closed in my pom
– sys463
Nov 13 '18 at 10:51
@gjoranv, no I have not. Does it make any sense, since I've declared in
<pluginManagement>
?– sys463
Nov 13 '18 at 10:53
It's easy to verify. Either, move the 'plugins' block directly under 'build' instead of 'pluginManagement'. Or just add the plugins inside 'build' without any version or config, which will then be "inherited" from pluginManagement.
– gjoranv
Nov 13 '18 at 11:23