Index: src/test/java/org/apache/maven/plugin/dependency/TestDirectoryArtifacts.java
===================================================================
--- src/test/java/org/apache/maven/plugin/dependency/TestDirectoryArtifacts.java	(revision 0)
+++ src/test/java/org/apache/maven/plugin/dependency/TestDirectoryArtifacts.java	(revision 0)
@@ -0,0 +1,105 @@
+package org.apache.maven.plugin.dependency;
+
+import java.io.File;
+import java.io.FileOutputStream;
+import java.io.IOException;
+import java.util.HashSet;
+import java.util.LinkedHashSet;
+
+import org.apache.maven.artifact.Artifact;
+import org.apache.maven.plugin.dependency.utils.DependencyUtil;
+import org.apache.maven.plugin.testing.ArtifactStubFactory;
+
+public class TestDirectoryArtifacts extends
+		AbstractDependencyMojoTestCase 
+{
+
+	private CopyDependenciesMojo copyMojo;
+	private UnpackDependenciesMojo unpackMojo;
+
+	protected void setUp() throws Exception 
+	{
+        // required for mojo lookups to work
+        super.setUp( "copy-dependencies", false );
+
+        File testPom = new File( getBasedir(), "target/test-classes/unit/copy-dependencies-test/plugin-config.xml" );
+        copyMojo = (CopyDependenciesMojo) lookupMojo( "copy-dependencies", testPom );
+        copyMojo.outputDirectory = new File( this.testDir, "copyOutputDirectory" );
+        // mojo.silent = true;
+
+        assertNotNull( copyMojo );
+        assertNotNull( copyMojo.getProject() );
+
+        testPom = new File( getBasedir(), "target/test-classes/unit/unpack-dependencies-test/plugin-config.xml" );
+        unpackMojo = (UnpackDependenciesMojo) lookupMojo( "unpack-dependencies", testPom );
+        unpackMojo.outputDirectory = new File( this.testDir, "unpackOutputDirectory" );
+
+        assertNotNull( unpackMojo );
+        assertNotNull( unpackMojo.getProject() );
+
+        copyMojo.markersDirectory = new File( this.testDir, "copyMarkers" );
+        unpackMojo.markersDirectory = new File( this.testDir, "unpackMarkers" );
+	}
+
+
+    public void testDirectoryArtifactCopy()
+    	throws Exception
+	{
+    	LinkedHashSet artifacts = new LinkedHashSet();
+
+    	Artifact artifact = stubFactory.createArtifact("a", "a", "1.0.0");
+    	createDirectory(artifact);
+    	
+    	artifacts.add(artifact);
+
+        copyMojo.project.setArtifacts( artifacts );
+        copyMojo.project.setDependencyArtifacts( new HashSet() );
+        copyMojo.execute();
+
+        String fileName = DependencyUtil.getFormattedFileName( artifact, false );
+        File file = new File( copyMojo.outputDirectory, fileName );
+
+        assertTrue( file.exists() );
+        assertTrue( file.isDirectory() );
+        
+	}
+
+	public void testDirectoryArtifactUnpack()
+		throws Exception
+	{
+	    	LinkedHashSet artifacts = new LinkedHashSet();
+
+	    	Artifact artifact = stubFactory.createArtifact("a", "b", "1.0.0");
+	    	createDirectory(artifact);
+
+	    	artifacts.add(artifact);
+
+	        unpackMojo.project.setArtifacts( artifacts );
+	        unpackMojo.project.setDependencyArtifacts( artifacts );
+	        unpackMojo.execute();
+
+	        String fileName = DependencyUtil.getFormattedFileName( artifact, false );
+	        File file = new File( unpackMojo.outputDirectory, fileName );
+
+	        assertTrue( file.exists() );
+	        assertTrue( file.isDirectory() );
+	}
+
+    private void createDirectory(Artifact artifact) throws IOException {
+		File workingDir = stubFactory.getWorkingDir();
+        if ( workingDir == null )
+        {
+            throw new IllegalArgumentException( "The workingDir must be set if createFiles is true." );
+        }
+        String fileName = ArtifactStubFactory.getFormattedFileName( artifact, false );
+        File theFile = new File( workingDir, fileName );
+        theFile.mkdirs();
+
+        FileOutputStream os = new FileOutputStream(new File(theFile, "afile.txt"));
+        os.flush();
+        os.close();
+
+        artifact.setFile( theFile );
+    }
+
+}
Index: src/main/java/org/apache/maven/plugin/dependency/AbstractDependencyMojo.java
===================================================================
--- src/main/java/org/apache/maven/plugin/dependency/AbstractDependencyMojo.java	(revision 713759)
+++ src/main/java/org/apache/maven/plugin/dependency/AbstractDependencyMojo.java	(working copy)
@@ -20,6 +20,7 @@
  */
 
 import java.io.File;
+import java.io.IOException;
 import java.lang.reflect.Field;
 import java.util.List;
 
@@ -192,7 +193,15 @@
             theLog.info( "Copying "
                 + ( this.outputAbsoluteArtifactFilename ? artifact.getAbsolutePath() : artifact.getName() ) + " to "
                 + destFile );
-            FileUtils.copyFile( artifact, destFile );
+
+            if ( artifact.isDirectory() )
+            {
+            	FileUtils.copyDirectoryStructure( artifact, destFile );
+            }
+            else
+            {
+            	FileUtils.copyFile( artifact, destFile );
+            }
 
         }
         catch ( Exception e )
@@ -223,6 +232,13 @@
     protected void unpack ( File file, File location, String includes, String excludes )
         throws MojoExecutionException
     {
+    	if ( file.isDirectory() )
+    	{
+            copyDirectory(file, location, includes, excludes);
+
+    		return;
+    	}
+
         try
         {
             getLog().info(
@@ -277,6 +293,28 @@
         }
     }
 
+	protected void copyDirectory( File src, File dest, String includes, String excludes ) 
+			throws MojoExecutionException 
+	{
+		getLog().info(
+		        "Copying " + src.getPath() + " to\n  " + dest.getPath()
+		            + "\n   with includes " + includes + " and excludes:" + excludes );
+
+		File realDest = new File( dest, src.getName() );
+		realDest.mkdirs();
+
+		try 
+		{
+			FileUtils.copyDirectory( src, realDest, includes, includes );
+		} 
+		catch (IOException e) 
+		{
+		    e.printStackTrace();
+		    throw new MojoExecutionException( "Error copying directory: " + src + " to: " + dest + "\r\n"
+		        + e.toString(), e );
+		}
+	}
+
     private void silenceUnarchiver ( UnArchiver unArchiver )
     {
         // dangerous but handle any errors. It's the only
