diff --git a/pom.xml b/pom.xml index 968b549..e839d85 100644 --- a/pom.xml +++ b/pom.xml @@ -20,13 +20,6 @@ UTF-8 - - - repo.bodar.com - http://repo.bodar.com - - - org.mozilla @@ -44,12 +37,6 @@ 1.1.1 true - - com.googlecode.totallylazy - totallylazy - 1163 - true - org.apache.commons commons-lang3 diff --git a/src/main/java/org/lesscss/JarURLResolver.java b/src/main/java/org/lesscss/JarURLResolver.java deleted file mode 100644 index 304a59e..0000000 --- a/src/main/java/org/lesscss/JarURLResolver.java +++ /dev/null @@ -1,44 +0,0 @@ -package org.lesscss; - -import java.io.IOException; -import java.net.URL; -import java.net.URLConnection; - -import static com.googlecode.totallylazy.Sequences.sequence; -import static com.googlecode.totallylazy.Strings.string; - -public class JarURLResolver implements LessResolver { - private String path; - - public JarURLResolver(String path) { - this.path = path; - } - - public boolean exists(String filename) { - return connection(filename).getLastModified() != 0; - } - - public String resolve(String filename) throws IOException { - return string(connection(filename).getInputStream()); - } - - public long getLastModified(String filename) { - return connection(filename).getLastModified(); - } - - public LessResolver resolveImport(String parent) { - return new JarURLResolver(sequence(full(parent).split("/")).init().toString("", "/", "/")); - } - - private URLConnection connection(String file) { - try { - return new URL(full(file)).openConnection(); - } catch (IOException e) { - throw new RuntimeException(e); - } - } - - private String full(String file) { - return path + file; - } -} \ No newline at end of file