]> git.phdru.name Git - bookmarks_db.git/blobdiff - parse_html/__init__.py
Change parse_html to parse strings, not files
[bookmarks_db.git] / parse_html / __init__.py
index 1e9393cc0d9263e48270118dffa1353d76dcb819..d9dfffc679a005073f70aca1213ab8b559b78f74 100644 (file)
@@ -1,16 +1,17 @@
 """HTML Parsers
 
 This file is a part of Bookmarks database and Internet robot.
+
 """
 
 __author__ = "Oleg Broytman <phd@phdru.name>"
-__copyright__ = "Copyright (C) 1997-2012 PhiloSoft Design"
+__copyright__ = "Copyright (C) 1997-2014 PhiloSoft Design"
 __license__ = "GNU GPL"
 
-__all__ = ['parse_html', 'main']
+__all__ = ['parse_html', 'parse_filename', 'main']
 
 
-from .bkmk_parse_html import parse_html
+from .bkmk_parse_html import parse_html, parse_filename
 
 
 def main():
@@ -27,6 +28,6 @@ def main():
    else:
       sys.exit("Usage: main filename [charset]")
 
-   parser = parse_html(filename, charset, log=lambda s: sys.stdout.write(s + '\n'))
+   parser = parse_filename(filename, charset, log=lambda s: sys.stdout.write(s + '\n'))
    print "   refresh:", parser.refresh
    print "   icon   :", parser.icon