Re: exec maven goals from java fails - invalid plugin descriptor
Hi, I had a kinda similar problem, I think it has to do with the version of exec-maven-plugin you are using 1.2 try changing it. On Wed, Jun 27, 2012 at 2:02 PM, Shaddow89 hagemeier.an...@googlemail.comwrote: Hi, i am currently developing a maven plugin that invokes several other plugins while it is executed. Therefore i use MavenCli: StringBuffer commands = new StringBuffer(); commands.append(org.codehaus.mojo:exec-maven-plugin:1.2:exec ); commands.append(-Dexecutable=src/main/resources/test.sh ); MavenCli.main(commands.toString().split( ), new Classworld()); If i execute this code from a standard java class, this execution will work. If I use this code in my plugin, and execute the plugin from an other project, the following exception occurs: Internal error in the plugin manager getting plugin 'org.codehaus.mojo:exec-maven-plugin': Plugin 'org.codehaus.mojo:exec-maven-plugin:1.2' has an invalid descriptor: 1) Plugin's descriptor contains the wrong group ID: tmp 2) Plugin's descriptor contains the wrong artifact ID: generate-dependencies-maven-plugin 3) Plugin's descriptor contains the wrong version: 0.0.1-SNAPSHOT 4) Plugin's descriptor contains the wrong group ID: org.apache.maven.plugins 5) Plugin's descriptor contains the wrong artifact ID: maven-dependency-plugin 6) Plugin's descriptor contains the wrong version: 2.4 I gooled this error and most people suggest wiping the local maven repo. But this didnt help at all. Furthermore, this error does not depend on the exec plugin. I have another part of my code, where i use the install plugin, which causes the same error. Is the general approach of invoking the goals wrong? I cannot configure the plugins, which are to be invoked, in the final project. My plugin needs to invoke the other goals. Ideas are highly welcome -- View this message in context: http://maven.40175.n5.nabble.com/exec-maven-goals-from-java-fails-invalid-plugin-descriptor-tp5712214.html Sent from the Maven - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Problem with maven for php
Hi, I'm trying to build a new project using mvn archetype:generate -DarchetypeArtifactId=php5-zend-archetype -X It gives me the following error [DEBUG] Archetype org.apache.maven.archetypes:php5-zend-archetype:1.0 doesn't exist org.apache.maven.archetype.downloader.DownloadNotFoundException: Requested org.apache.maven.archetypes:php5-zend-archetype:jar:1.0 download does not exist. at org.apache.maven.archetype.downloader.DefaultDownloader.download(DefaultDownloader.java:78) at org.apache.maven.archetype.common.DefaultArchetypeArtifactManager.exists(DefaultArchetypeArtifactManager.java:272) at org.apache.maven.archetype.ui.generation.DefaultArchetypeGenerationConfigurator.configureArchetype(DefaultArchetypeGenerationConfigurator.java:114) at org.apache.maven.archetype.mojos.CreateProjectFromArchetypeMojo.execute(CreateProjectFromArchetypeMojo.java:205) at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101) at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209) at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153) at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145) at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84) at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59) at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183) at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161) at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:319) at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156) at org.apache.maven.cli.MavenCli.execute(MavenCli.java:537) at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:196) at org.apache.maven.cli.MavenCli.main(MavenCli.java:141) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:290) at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:230) at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:409) at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:352) Caused by: org.apache.maven.artifact.resolver.ArtifactNotFoundException: Failure to find org.apache.maven.archetypes:php5-zend-archetype:jar:1.0 in http://repo1.php-maven.org/release was cached in the local repository, resolution will not be reattempted until the update interval of release-repo1.php-maven.org has elapsed or updates are forced Try downloading the file manually from the project website. Then, install it using the command: mvn install:install-file -DgroupId=org.apache.maven.archetypes -DartifactId=php5-zend-archetype -Dversion=1.0 -Dpackaging=jar -Dfile=/path/to/file Alternatively, if you host your own repository you can deploy the file there: mvn deploy:deploy-file -DgroupId=org.apache.maven.archetypes -DartifactId=php5-zend-archetype -Dversion=1.0 -Dpackaging=jar -Dfile=/path/to/file -Durl=[url] -DrepositoryId=[id] org.apache.maven.archetypes:php5-zend-archetype:jar:1.0 from the specified remote repositories: release-repo1.php-maven.org (http://repo1.php-maven.org/release, releases=true, snapshots=true), snapshot-repo1.php-maven.org (http://repo1.php-maven.org/snapshot, releases=false, snapshots=true), central (http://repo1.maven.org/maven2, releases=true, snapshots=false) at org.apache.maven.artifact.resolver.DefaultArtifactResolver.resolve(DefaultArtifactResolver.java:219) at org.apache.maven.artifact.resolver.DefaultArtifactResolver.resolve(DefaultArtifactResolver.java:157) at org.apache.maven.artifact.resolver.DefaultArtifactResolver.resolve(DefaultArtifactResolver.java:525) at org.apache.maven.archetype.downloader.DefaultDownloader.download(DefaultDownloader.java:70) ... 24 more Caused by: org.sonatype.aether.resolution.ArtifactResolutionException: Failure to find org.apache.maven.archetypes:php5-zend-archetype:jar:1.0 in http://repo1.php-maven.org/release was cached in the local repository, resolution will not be reattempted until the update interval of release-repo1.php-maven.org has elapsed or updates are forced at org.sonatype.aether.impl.internal.DefaultArtifactResolver.resolve(DefaultArtifactResolver.java:541) at org.sonatype.aether.impl.internal.DefaultArtifactResolver.resolveArtifacts(DefaultArtifactResolver.java:220) at org.sonatype.aether.impl.internal.DefaultArtifactResolver.resolveArtifact(DefaultArtifactResolver.java:197) at org.sonatype.aether.impl.internal.DefaultRepositorySystem.resolveArtifact(DefaultRepositorySystem.java:323)