Conflicts:
manga/mangafox.py
-import urllib
+import urllib, re
import BeautifulSoup
import lib, htcache
soup = BeautifulSoup.BeautifulSoup
return el
class manga(lib.manga):
+ cure = re.compile(r"/v\d+/c[\d.]+/$")
+
def __init__(self, lib, id, name, url):
self.lib = lib
self.id = id
url = n.a["href"].encode("us-ascii")
if url[-7:] == "/1.html":
url = url[:-6]
- elif url[-1:] == "/":
+ elif self.cure.search(url) is not None:
pass
else:
raise Exception("parse error: unexpected chapter URL for %r: %s" % (self, url))
for nm, (libnm, id) in map.iteritems():
f.write(consline("alias", nm, libnm, id) + "\n")
+ def file(self, name, mode="r"):
+ return openwdir(pj(self.dir, name), mode)
+
def getalias(self, nm):
return self.getaliases()[nm]