Maven in 5 Minutes issue

前端 未结 6 1427
夕颜
夕颜 2021-02-14 04:17

I\'m following Maven in 5 Minutes manual with the following:

mvn archetype:generate -DgroupId=com.mycompany.app -DartifactId=my-app -DarchetypeArtifactId=maven-a         


        
6条回答
  •  野性不改
    2021-02-14 04:48

    I ran into the same problem, and it looks like we have the similar setup

    • Windows 7
    • Powershell
    • HTTP proxy

    here is what I have to do:

    1. Wrap all the "-D..." inside double quotes, e.g.

      mvn archetype:generate "-DarchetypeGroupId=org.apache.maven.archetypes" "-DarchetypeArtifactId=maven-archetype-quickstart" "-DgroupId=com.mycompany.app" "-DartifactId=my-app"
      
    2. Make sure you have "HTTP_PROXY" set properly in your envrironment variables (check it by typing "echo $Env:HTTP_PROXY")

提交回复
热议问题