public static function stripBase($path, $base = null) {
        if ($base === null)
            $base = getcwd();
        if (substr($path, 0, strlen($base)) === $base)
            return ltrim(substr($path, strlen($base) + 1), "/");
        else
            throw new PathException("\"$path\" does not contain base path \"$base\"");
    }