java 什么是“选择一个数字或应用过滤器(格式:[groupId:]artifactId,包含大小写敏感)”
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/31780926/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
What is "Choose a number or apply filter (format: [groupId:]artifactId, case sensitive contains)"
提问by DeskToDevelop
I am new in Maven and tried creating Maven project using command line.
When I run mvn archetype:generate
from the command line
The first thing after completion of all processes were:
我是 Maven 新手,并尝试使用命令行创建 Maven 项目。当我从命令行运行mvn archetype:generate
所有进程完成后的第一件事是:
Choose a number or apply filter (format: [groupId:]artifactId, case sensitive contains)
I know we can skip these by pressing an Enter. But I really wanted to know what exactly these lines are? I googled but there is no crisp and simple answer given. My questions are:
我知道我们可以通过按 Enter 跳过这些。但我真的很想知道这些线条到底是什么?我用谷歌搜索,但没有给出清晰而简单的答案。我的问题是:
- Why and how to choose a number, how its related to filter (as filter and number are in OR).
- We can skip these then why it is given by Maven..
- Why this number 630specifically is displayed.
- Is there any default value is assigned when we skip these lines by pressing Enter.[This is more important]
- 为什么以及如何选择一个数字,它与过滤器的关系(因为过滤器和数字在 OR 中)。
- 我们可以跳过这些然后为什么它是由 Maven 给出的..
- 为什么要特别显示这个数字630。
- 当我们按 Enter 键跳过这些行时,是否分配了任何默认值。[这更重要]
Looking for sharp and crisp answer or link.
寻找清晰明了的答案或链接。
Update : These are the few lines just before "choose a number.." appears..
更新:这些是“选择一个数字..”出现之前的几行..
1380: remote -> tr.com.lucidcode:kite-archetype (A Maven Archetype that allows u
sers to create a Fresh Kite project)
1381: remote -> uk.ac.rdg.resc:edal-ncwms-based-webapp (-)
1382: remote -> uk.co.nemstix:basic-javaee7-archetype (A basic Java EE7 Maven ar
chetype)
1383: remote -> us.fatehi:schemacrawler-archetype-maven-project (-)
1384: remote -> us.fatehi:schemacrawler-archetype-plugin-command (-)
1385: remote -> us.fatehi:schemacrawler-archetype-plugin-dbconnector (-)
1386: remote -> us.fatehi:schemacrawler-archetype-plugin-lint (-)
**Choose a number or apply filter (format: [groupId:]artifactId, case sensitive co
ntains): 630:**
Choose org.apache.maven.archetypes:maven-archetype-quickstart version:
1: 1.0-alpha-1
2: 1.0-alpha-2
3: 1.0-alpha-3
4: 1.0-alpha-4
5: 1.0
6: 1.1
Choose a number: 6:
回答by Ankush soni
Command mvn archetype:generate:
命令 mvn 原型:生成:
Generates a new project from an archetype, or updates the actual project if using a partial archetype. If the project is fully generated, it is generated in a directory corresponding to its artifactId. If the project is updated with a partial archetype, it is done in the current directory.
从原型生成新项目,或者如果使用部分原型则更新实际项目。如果项目完全生成,则生成在其 artifactId 对应的目录中。如果项目使用部分原型更新,则在当前目录中完成。
There are more then 1000 archetype are available in Maven, when ever you select any one of them it will generate and sample Maven project for you, which will include the dependencies in pom.xml by default.
Maven 中有超过 1000 个可用的原型,当您选择其中任何一个时,它都会为您生成和示例 Maven 项目,默认情况下将包含 pom.xml 中的依赖项。
630 is by default and basically for : remote -> org.apache.maven.archetypes:maven-archetype-quickstart
630 是默认的,基本上用于:remote -> org.apache.maven.archetypes:maven-archetype-quickstart