public static boolean zipFile( String sourceDir, String destinationFile, String... excludes ) {
        File srcDir = new File( sourceDir );
        if( !srcDir.exists() )
            return( false );

        // Delete the file if it exists.
        File destFile = new File( destinationFile );
        if( destFile.exists() )
            destFile.delete();

        // Try to create the required directories and exit if it fails.
        if( !destFile.getParentFile().exists() && !destFile.getParentFile().mkdirs() )
            return( false );

        ZipOutputStream zout = null;
        try {
            zout = new ZipOutputStream( new FileOutputStream( destFile ) );
            zipFileRec( srcDir, "", zout, Arrays.asList(excludes));
        }
        catch( IOException ex ) {
            ex.printStackTrace();
            return( false );
        }
        finally {
            try {
                zout.close();
            }
            catch( IOException ex ) {
                ex.printStackTrace();
                return( false );
            }
        }

        return( true );
    }