[sync] + pages support
This commit is contained in:
1 parent
59cbcc7886
commit
714ceb2ac8
6 files changed
+178
-2
No files matched your search
@@ -93,6 +93,16 @@ def images_from_html(md):
|
||||
return images
|
||||
|
||||
|
||||
def title_from_html(md):
|
||||
if not md:
|
||||
return None
|
||||
|
||||
doc = lxml.html.fromstring(md)
|
||||
ts = doc.cssselect('h1')
|
||||
if len(ts):
|
||||
return ts[0].text
|
||||
|
||||
|
||||
create_post_from_image_list = lambda images: markdown(
|
||||
'\n'.join(map(
|
||||
lambda i: ''.format(img=i),
|
||||
|
||||
Reference in new issue
Block a user