Commit c7e12d32 authored by rgauss's avatar rgauss
Browse files

- Added skipWarManifestCheck property which disables the check for a manifest file in warLocation

Fixes issue 109


git-svn-id: http://maven-alfresco-archetypes.googlecode.com/svn/trunk@663 04253f4f-3451-0410-a141-5562f1e59037
parent ed0bde63
Loading
Loading
Loading
Loading
+8 −1
Original line number Diff line number Diff line
@@ -64,6 +64,13 @@ public class InstallMojo extends AbstractMojo {
     */
    private boolean backup;
    
    /**
     * Whether or not to skip the check for a manifest file in the warLocation
     * 
     * @parameter property="maven.alfresco.skipWarManifestCheck" default-value="false"
     */
    private boolean skipWarManifestCheck;

    public InstallMojo() {
    }

@@ -113,7 +120,7 @@ public class InstallMojo extends AbstractMojo {
            throw new MojoExecutionException("No webapp found in " + descriptor.getAbsolutePath() + ". AMP installation cannot proceed. Are you binding amp:install to the right phase?");
        
        File manifest = new File(warLocation.getPath() + File.separator + WEBAPP_MANIFEST_PATH); 
        if(warLocation.isDirectory() && !manifest.exists())
        if(!skipWarManifestCheck && warLocation.isDirectory() && !manifest.exists())
            throw new MojoExecutionException("No MANIFEST.MF found in " + manifest.getAbsolutePath() + ". AMP installation cannot proceed. Are you binding amp:install to the right phase?");
    }
}
 No newline at end of file