You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by "Brett Porter (JIRA)" <ji...@codehaus.org> on 2006/01/03 09:43:12 UTC

[jira] Closed: (MASSEMBLY-5) mvn assembly:assembly fails if there is no target directory already present

     [ http://jira.codehaus.org/browse/MASSEMBLY-5?page=all ]
     
Brett Porter closed MASSEMBLY-5:
--------------------------------

      Assign To: Brett Porter
     Resolution: Fixed
    Fix Version: 2.1

I simply ignored the directory if it didn't exist, rather than creating an empty one

> mvn assembly:assembly fails if there is no target directory already present
> ---------------------------------------------------------------------------
>
>          Key: MASSEMBLY-5
>          URL: http://jira.codehaus.org/browse/MASSEMBLY-5
>      Project: Maven 2.x Assembly Plugin
>         Type: Bug

>     Reporter: Matthew Pocock
>     Assignee: Brett Porter
>     Priority: Minor
>      Fix For: 2.1
>  Attachments: MNG1578.patch
>
>
> I have a module that is of type pom. Its job is to agregate a set of dependencies. I want to build a distribution from these, so I tried the assembly plugin. I did get it to work. However, on the way I got this error:
> [INFO] [assembly:assembly]
> [INFO] ----------------------------------------------------------------------------
> [ERROR] BUILD ERROR
> [INFO] ----------------------------------------------------------------------------
> [INFO] Error creating assembly: /home/nmrp3/devel/derkholm/bjv2/trunk/clis/cli/target isn't a directory.
> A build for a pom project doesn't make a target directory. But, assembly:assembly requires one. I've made the directory manually and now the assembly builds just fine. The stack-trace is below. I've modified my assembly descriptor file to not mention target/** at all, and it now builds just fine without the target directory being present.
> The path of least suprise for the end-user would be to behave as if there were no files to find if target is absent and a search is done within target for files.
> [DEBUG] Trace
> org.apache.maven.lifecycle.LifecycleExecutionException: Error creating assembly: /home/nmrp3/devel/derkholm/bjv2/trunk/clis/cli/target isn't a directory.
>         at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:544)
>         at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:482)
>         at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:452)
>         at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:301)
>         at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:214)
>         at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:137)
>         at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:322)
>         at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:115)
>         at org.apache.maven.cli.MavenCli.main(MavenCli.java:243)
>         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:585)
>         at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
>         at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
>         at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
>         at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
> Caused by: org.apache.maven.plugin.MojoExecutionException: Error creating assembly: /home/nmrp3/devel/derkholm/bjv2/trunk/clis/cli/target isn't a directory.
>         at org.apache.maven.plugin.assembly.AssemblyMojo.execute(AssemblyMojo.java:173)
>         at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:412)
>         at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:519)
>         ... 16 more
> Caused by: org.codehaus.plexus.archiver.ArchiverException: /home/nmrp3/devel/derkholm/bjv2/trunk/clis/cli/target isn't a directory.
>         at org.codehaus.plexus.archiver.AbstractArchiver.addDirectory(AbstractArchiver.java:125)
>         at org.apache.maven.plugin.assembly.AssemblyMojo.addDirectory(AssemblyMojo.java:377)
>         at org.apache.maven.plugin.assembly.AssemblyMojo.processFileSets(AssemblyMojo.java:459)
>         at org.apache.maven.plugin.assembly.AssemblyMojo.createArchive(AssemblyMojo.java:209)
>         at org.apache.maven.plugin.assembly.AssemblyMojo.execute(AssemblyMojo.java:165)
>         ... 18 more
> [INFO] ----------------------------------------------------------------------------
> [INFO] Total time: 8 seconds
> [INFO] Finished at: Tue Nov 15 16:03:51 GMT 2005
> [INFO] Final Memory: 3M/6M
> [INFO] ----------------------------------------------------------------------------

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org