Have you tried adding some double-quotes around arguments? like: mvn.bat archetype:create "-DgroupId=com.mycompany.app" -DartifactId=my-app
I don't have a powershell to test, but as you can saw " Invalid task '.mycompany.app' " means that the argument line was split incorrectly Maybe it is the 'com' that mess, maybe it is the dot. Regards, Raphaël 2008/4/18 Marc Weidner <[EMAIL PROTECTED]>: > Hi, > > I'm having issues regarding using Maven 2.0.9 with Microsoft Windows > PowerShell 1.0 and JDK 1.6.0_05. > > I start PowerShell and set the JAVA_HOME environment variable via > $env:JAVA_HOME = "path-to-jdk". > > When I issue the command mvn -version I get the version information > displayed. Then I want to create the sample project via the following > command: > > C:\Programme\apache-maven-2.0.9\bin\mvn.bat archetype:create > -DgroupId=com.mycompany.app -DartifactId=my-app > > I get the following error message: > > [INFO] Scanning for projects... > [INFO] Searching repository for plugin with prefix: 'archetype'. > [INFO] > ------------------------------------------------------------------------ > [ERROR] BUILD FAILURE > [INFO] > ------------------------------------------------------------------------ > [INFO] Invalid task '.mycompany.app': you must specify a valid lifecycle > phase, or a goal in the format plugin:goal or > pluginGroupId:pluginArtifactId:pluginVersion:goal > [INFO] > ------------------------------------------------------------------------ > [INFO] For more information, run Maven with the -e switch > [INFO] > ------------------------------------------------------------------------ > [INFO] Total time: < 1 second > [INFO] Finished at: Fri Apr 18 11:57:00 CEST 2008 > [INFO] Final Memory: 2M/4M > [INFO] > ------------------------------------------------------------------------ > > If I run the command via the good old cmd.exe all works fine. Can someone > confirm this behavior? > > Regards > > Marc Weidner > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >