PDA

View Full Version : سوال: ایجاد یک پروژه جاوا با استفاده از maven



farshaf
شنبه 26 مهر 1393, 18:02 عصر
سلام

من به تازگی شروع به یادگیری ابزار maven کردم که از یک tutorial این کار رو میکنم. در ابتدای فصل هشت ایجاد یک پروژه جاوا رو گفته ولی وقتی من دستور maven archetype:generate
-DgroupId=com.companyname.bank -DartifactId=consumerBanking -DarchetypeArtifactId=maven-archetype-quickstart -DinteractiveMode=false رو در cmd میزنم به جای ایجاد یک پروژه در دایرکتوری جاری خطای زیر رو صادر میکنه نمیدونم دلیلش چیه؟ احتمال میدم که نمیتونه به نت وصل شه و پلاگین archetype رو دانلود کنه ولی نمیدونم چطور مشکلم رو برطرف کنم.
خطایی که بعد از نوشتن دستور در cmd مینویسه این هست:

[INFO] Scanning for projects...
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-clean-plugin/2.5/maven-clean-plugin-2.5.pom

[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-clean-plugin:2.5: Plugin org.apache.maven.plugins:maven-clean-plugin:2.5 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-clean-plugin:jar:2.5
Downloading: https://repo.maven.apache.org/maven2/org/apache/maven/plugins/maven-install-plugin/2.4/maven-install-plugin-2.4.pom

[WARNING] Failed to retrieve plugin descriptor for org.apache.maven.plugins:maven-install-plugin:2.4: Plugin org.apache.maven.plugins:maven-install-plugin:2.4 or one of its dependencies could not be resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-install-plugin:jar:2.4
.
.
.
.
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 5.167 s
[INFO] Finished at: 2012-05-18T21:09:38-07:00
[INFO] Final Memory: 3M/254M
[INFO] ------------------------------------------------------------------------
[ERROR] No plugin found for prefix 'archetype' in the current project and in the plugin groups [org.apache.maven.plugins, org.codehaus.mojo] available from the repositories [local (C:\Users\a\.m2\repository), central (https://repo.maven.apache.org/maven2)] -> [Help 1]
[ERROR]

خیلی سپاسگذارم از دوستانی که کمک میکنند :)

cups_of_java
شنبه 26 مهر 1393, 21:22 عصر
از archetypeArtifactId به جای archetypeId استفاده کنید ببینید تاثیر داره...