public static URL getUrlOfZippedVersion(URL repoURL, String suffix, boolean returnAlternateArchives) throws MalformedURLException, IOException {
        BufferedReader reader = new BufferedReader(new InputStreamReader(repoURL.openStream()));
        suffix = suffix.trim();
        String line;
        String toReturn = null;
        String alternativeReturn = null;
        while ((line = reader.readLine()) != null) {
            if (line.toLowerCase(LOCALE).contains("href=") && line.toLowerCase(LOCALE).contains(suffix)) {
                toReturn = line.substring(line.indexOf("href=\"") + 6,line.indexOf(suffix,line.indexOf("href=\""))+suffix.length());
                break;
            } else if (line.toLowerCase(LOCALE).contains(".zip") || line.toLowerCase(LOCALE).contains(".tar.gz") || line.toLowerCase(LOCALE).contains(".bz") && returnAlternateArchives) {
                alternativeReturn = line.substring(line.indexOf("href=\"") + 6, line.indexOf(line.indexOf("href=\"") + 6, line.indexOf(">")));
            }
        }
        reader.close();
        if (returnAlternateArchives && toReturn == null) {
            toReturn = alternativeReturn;
        }
        return new URL(new StringBuilder().append(repoURL.toExternalForm()).append("/").append(toReturn).toString());
    }