netbeans can't find maven project
I am learning maven, in one book they asked me to execute this on cmd and it works fine
$ mvn archetype:generate -DgroupId=org.sonatype.mavenbook.simple
-DartifactId=simple -DpackageName=org.sonatype.mavenbook -Dversion=1.0-SNAPSHOT
but in netbeans whe I choose "project from archetype" the build fail and it tells me this:
Generating project in Batch mode Archetype not found in any catalog.
Falling back to central repository. Add a repsoitory with id
'archetype' in your settings.xml if archetype's repository is
elsewhere. The POM for
org.sonatype.mavenbook.simple:simple:jar:1.0-SNAPSHOT is missing, no
dependency information available
BUILD FAILURE
java maven netbeans
add a comment |
I am learning maven, in one book they asked me to execute this on cmd and it works fine
$ mvn archetype:generate -DgroupId=org.sonatype.mavenbook.simple
-DartifactId=simple -DpackageName=org.sonatype.mavenbook -Dversion=1.0-SNAPSHOT
but in netbeans whe I choose "project from archetype" the build fail and it tells me this:
Generating project in Batch mode Archetype not found in any catalog.
Falling back to central repository. Add a repsoitory with id
'archetype' in your settings.xml if archetype's repository is
elsewhere. The POM for
org.sonatype.mavenbook.simple:simple:jar:1.0-SNAPSHOT is missing, no
dependency information available
BUILD FAILURE
java maven netbeans
could you include your pom file?
– JoSSte
Nov 19 '18 at 12:22
add a comment |
I am learning maven, in one book they asked me to execute this on cmd and it works fine
$ mvn archetype:generate -DgroupId=org.sonatype.mavenbook.simple
-DartifactId=simple -DpackageName=org.sonatype.mavenbook -Dversion=1.0-SNAPSHOT
but in netbeans whe I choose "project from archetype" the build fail and it tells me this:
Generating project in Batch mode Archetype not found in any catalog.
Falling back to central repository. Add a repsoitory with id
'archetype' in your settings.xml if archetype's repository is
elsewhere. The POM for
org.sonatype.mavenbook.simple:simple:jar:1.0-SNAPSHOT is missing, no
dependency information available
BUILD FAILURE
java maven netbeans
I am learning maven, in one book they asked me to execute this on cmd and it works fine
$ mvn archetype:generate -DgroupId=org.sonatype.mavenbook.simple
-DartifactId=simple -DpackageName=org.sonatype.mavenbook -Dversion=1.0-SNAPSHOT
but in netbeans whe I choose "project from archetype" the build fail and it tells me this:
Generating project in Batch mode Archetype not found in any catalog.
Falling back to central repository. Add a repsoitory with id
'archetype' in your settings.xml if archetype's repository is
elsewhere. The POM for
org.sonatype.mavenbook.simple:simple:jar:1.0-SNAPSHOT is missing, no
dependency information available
BUILD FAILURE
java maven netbeans
java maven netbeans
edited Nov 19 '18 at 12:16
migano
asked Nov 19 '18 at 8:26
miganomigano
134
134
could you include your pom file?
– JoSSte
Nov 19 '18 at 12:22
add a comment |
could you include your pom file?
– JoSSte
Nov 19 '18 at 12:22
could you include your pom file?
– JoSSte
Nov 19 '18 at 12:22
could you include your pom file?
– JoSSte
Nov 19 '18 at 12:22
add a comment |
1 Answer
1
active
oldest
votes
When you created the project from the command line you would have been invited to specify the archetype and version you wanted to use to create the project. Since you don't mention using any specific archetype you probably selected the default archetype which is version 1.3 of maven-archetype-quickstart.
Near the end of the output generated by calling mvn
from the command line you can see the archetype you chose for creating the project:
[INFO] ----------------------------------------------------------------------------
[INFO] Using following parameters for creating project from Archetype: maven-archetype-quickstart:1.3
[INFO] ----------------------------------------------------------------------------
[INFO] Parameter: groupId, Value: org.sonatype.mavenbook.simple
[INFO] Parameter: artifactId, Value: simple
[INFO] Parameter: version, Value: 1.0-SNAPSHOT
[INFO] Parameter: package, Value: org.sonatype.mavenbook.simple
[INFO] Parameter: packageInPathFormat, Value: org/sonatype/mavenbook/simple
[INFO] Parameter: package, Value: org.sonatype.mavenbook.simple
[INFO] Parameter: version, Value: 1.0-SNAPSHOT
[INFO] Parameter: groupId, Value: org.sonatype.mavenbook.simple
[INFO] Parameter: artifactId, Value: simple
[INFO] Project created from Archetype in dir: C:Usersjohndoesimple
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
However, when creating a Maven project from an archetype in NetBeans no assumption is made about the archetype you to use; you must specify it explicitly. I'm not sure what you submitted in NetBeans, but try this:
In NetBeans: File > New Project... > Maven > Project from Archetype
On the Maven Archetype screen search for
maven-archetype-quickstart
. I get presented with three choices in the search results, including two instances ofmaven-archetype-quickstart
. Select the one with the higher version number:
- Click Next > to accept the options, then click Finish on the next screen to create the project.
Notes:
- Even if you used a different archetype to create your project from the command line the same approach is applicable. Just search for the relevant archetype in NetBeans.
- When you create a Maven project using either approach a file named pom.xml will be created directly under the root of your project. It is worth comparing the content of the two instances of pom.xml to see any differences arising from creating the project in NetBeans. If you provided the same details for both projects the two instances of pom.xml should be identical.
thanks, it is working, your answer was informative
– migano
Nov 19 '18 at 20:54
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%2f53370810%2fnetbeans-cant-find-maven-project%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
When you created the project from the command line you would have been invited to specify the archetype and version you wanted to use to create the project. Since you don't mention using any specific archetype you probably selected the default archetype which is version 1.3 of maven-archetype-quickstart.
Near the end of the output generated by calling mvn
from the command line you can see the archetype you chose for creating the project:
[INFO] ----------------------------------------------------------------------------
[INFO] Using following parameters for creating project from Archetype: maven-archetype-quickstart:1.3
[INFO] ----------------------------------------------------------------------------
[INFO] Parameter: groupId, Value: org.sonatype.mavenbook.simple
[INFO] Parameter: artifactId, Value: simple
[INFO] Parameter: version, Value: 1.0-SNAPSHOT
[INFO] Parameter: package, Value: org.sonatype.mavenbook.simple
[INFO] Parameter: packageInPathFormat, Value: org/sonatype/mavenbook/simple
[INFO] Parameter: package, Value: org.sonatype.mavenbook.simple
[INFO] Parameter: version, Value: 1.0-SNAPSHOT
[INFO] Parameter: groupId, Value: org.sonatype.mavenbook.simple
[INFO] Parameter: artifactId, Value: simple
[INFO] Project created from Archetype in dir: C:Usersjohndoesimple
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
However, when creating a Maven project from an archetype in NetBeans no assumption is made about the archetype you to use; you must specify it explicitly. I'm not sure what you submitted in NetBeans, but try this:
In NetBeans: File > New Project... > Maven > Project from Archetype
On the Maven Archetype screen search for
maven-archetype-quickstart
. I get presented with three choices in the search results, including two instances ofmaven-archetype-quickstart
. Select the one with the higher version number:
- Click Next > to accept the options, then click Finish on the next screen to create the project.
Notes:
- Even if you used a different archetype to create your project from the command line the same approach is applicable. Just search for the relevant archetype in NetBeans.
- When you create a Maven project using either approach a file named pom.xml will be created directly under the root of your project. It is worth comparing the content of the two instances of pom.xml to see any differences arising from creating the project in NetBeans. If you provided the same details for both projects the two instances of pom.xml should be identical.
thanks, it is working, your answer was informative
– migano
Nov 19 '18 at 20:54
add a comment |
When you created the project from the command line you would have been invited to specify the archetype and version you wanted to use to create the project. Since you don't mention using any specific archetype you probably selected the default archetype which is version 1.3 of maven-archetype-quickstart.
Near the end of the output generated by calling mvn
from the command line you can see the archetype you chose for creating the project:
[INFO] ----------------------------------------------------------------------------
[INFO] Using following parameters for creating project from Archetype: maven-archetype-quickstart:1.3
[INFO] ----------------------------------------------------------------------------
[INFO] Parameter: groupId, Value: org.sonatype.mavenbook.simple
[INFO] Parameter: artifactId, Value: simple
[INFO] Parameter: version, Value: 1.0-SNAPSHOT
[INFO] Parameter: package, Value: org.sonatype.mavenbook.simple
[INFO] Parameter: packageInPathFormat, Value: org/sonatype/mavenbook/simple
[INFO] Parameter: package, Value: org.sonatype.mavenbook.simple
[INFO] Parameter: version, Value: 1.0-SNAPSHOT
[INFO] Parameter: groupId, Value: org.sonatype.mavenbook.simple
[INFO] Parameter: artifactId, Value: simple
[INFO] Project created from Archetype in dir: C:Usersjohndoesimple
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
However, when creating a Maven project from an archetype in NetBeans no assumption is made about the archetype you to use; you must specify it explicitly. I'm not sure what you submitted in NetBeans, but try this:
In NetBeans: File > New Project... > Maven > Project from Archetype
On the Maven Archetype screen search for
maven-archetype-quickstart
. I get presented with three choices in the search results, including two instances ofmaven-archetype-quickstart
. Select the one with the higher version number:
- Click Next > to accept the options, then click Finish on the next screen to create the project.
Notes:
- Even if you used a different archetype to create your project from the command line the same approach is applicable. Just search for the relevant archetype in NetBeans.
- When you create a Maven project using either approach a file named pom.xml will be created directly under the root of your project. It is worth comparing the content of the two instances of pom.xml to see any differences arising from creating the project in NetBeans. If you provided the same details for both projects the two instances of pom.xml should be identical.
thanks, it is working, your answer was informative
– migano
Nov 19 '18 at 20:54
add a comment |
When you created the project from the command line you would have been invited to specify the archetype and version you wanted to use to create the project. Since you don't mention using any specific archetype you probably selected the default archetype which is version 1.3 of maven-archetype-quickstart.
Near the end of the output generated by calling mvn
from the command line you can see the archetype you chose for creating the project:
[INFO] ----------------------------------------------------------------------------
[INFO] Using following parameters for creating project from Archetype: maven-archetype-quickstart:1.3
[INFO] ----------------------------------------------------------------------------
[INFO] Parameter: groupId, Value: org.sonatype.mavenbook.simple
[INFO] Parameter: artifactId, Value: simple
[INFO] Parameter: version, Value: 1.0-SNAPSHOT
[INFO] Parameter: package, Value: org.sonatype.mavenbook.simple
[INFO] Parameter: packageInPathFormat, Value: org/sonatype/mavenbook/simple
[INFO] Parameter: package, Value: org.sonatype.mavenbook.simple
[INFO] Parameter: version, Value: 1.0-SNAPSHOT
[INFO] Parameter: groupId, Value: org.sonatype.mavenbook.simple
[INFO] Parameter: artifactId, Value: simple
[INFO] Project created from Archetype in dir: C:Usersjohndoesimple
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
However, when creating a Maven project from an archetype in NetBeans no assumption is made about the archetype you to use; you must specify it explicitly. I'm not sure what you submitted in NetBeans, but try this:
In NetBeans: File > New Project... > Maven > Project from Archetype
On the Maven Archetype screen search for
maven-archetype-quickstart
. I get presented with three choices in the search results, including two instances ofmaven-archetype-quickstart
. Select the one with the higher version number:
- Click Next > to accept the options, then click Finish on the next screen to create the project.
Notes:
- Even if you used a different archetype to create your project from the command line the same approach is applicable. Just search for the relevant archetype in NetBeans.
- When you create a Maven project using either approach a file named pom.xml will be created directly under the root of your project. It is worth comparing the content of the two instances of pom.xml to see any differences arising from creating the project in NetBeans. If you provided the same details for both projects the two instances of pom.xml should be identical.
When you created the project from the command line you would have been invited to specify the archetype and version you wanted to use to create the project. Since you don't mention using any specific archetype you probably selected the default archetype which is version 1.3 of maven-archetype-quickstart.
Near the end of the output generated by calling mvn
from the command line you can see the archetype you chose for creating the project:
[INFO] ----------------------------------------------------------------------------
[INFO] Using following parameters for creating project from Archetype: maven-archetype-quickstart:1.3
[INFO] ----------------------------------------------------------------------------
[INFO] Parameter: groupId, Value: org.sonatype.mavenbook.simple
[INFO] Parameter: artifactId, Value: simple
[INFO] Parameter: version, Value: 1.0-SNAPSHOT
[INFO] Parameter: package, Value: org.sonatype.mavenbook.simple
[INFO] Parameter: packageInPathFormat, Value: org/sonatype/mavenbook/simple
[INFO] Parameter: package, Value: org.sonatype.mavenbook.simple
[INFO] Parameter: version, Value: 1.0-SNAPSHOT
[INFO] Parameter: groupId, Value: org.sonatype.mavenbook.simple
[INFO] Parameter: artifactId, Value: simple
[INFO] Project created from Archetype in dir: C:Usersjohndoesimple
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
However, when creating a Maven project from an archetype in NetBeans no assumption is made about the archetype you to use; you must specify it explicitly. I'm not sure what you submitted in NetBeans, but try this:
In NetBeans: File > New Project... > Maven > Project from Archetype
On the Maven Archetype screen search for
maven-archetype-quickstart
. I get presented with three choices in the search results, including two instances ofmaven-archetype-quickstart
. Select the one with the higher version number:
- Click Next > to accept the options, then click Finish on the next screen to create the project.
Notes:
- Even if you used a different archetype to create your project from the command line the same approach is applicable. Just search for the relevant archetype in NetBeans.
- When you create a Maven project using either approach a file named pom.xml will be created directly under the root of your project. It is worth comparing the content of the two instances of pom.xml to see any differences arising from creating the project in NetBeans. If you provided the same details for both projects the two instances of pom.xml should be identical.
answered Nov 19 '18 at 15:09
skomisaskomisa
6,21131738
6,21131738
thanks, it is working, your answer was informative
– migano
Nov 19 '18 at 20:54
add a comment |
thanks, it is working, your answer was informative
– migano
Nov 19 '18 at 20:54
thanks, it is working, your answer was informative
– migano
Nov 19 '18 at 20:54
thanks, it is working, your answer was informative
– migano
Nov 19 '18 at 20:54
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%2f53370810%2fnetbeans-cant-find-maven-project%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
could you include your pom file?
– JoSSte
Nov 19 '18 at 12:22