From a7e4e685c0e23b1302e82a903bc3bcee57cff85f Mon Sep 17 00:00:00 2001 From: Meekdai Date: Tue, 28 May 2024 21:40:26 +0800 Subject: [PATCH] Update Gmeek.py --- Gmeek.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/Gmeek.py b/Gmeek.py index ebc80e1..fc8b394 100644 --- a/Gmeek.py +++ b/Gmeek.py @@ -8,7 +8,6 @@ import shutil import urllib import requests import argparse -import html from github import Github from xpinyin import Pinyin from feedgen.feed import FeedGenerator @@ -159,8 +158,11 @@ class GMEEK(): f'color: var(--fgColor-{style},var(--color-{style}-fg));}}' ) - if '##{"html":' in post_body: - post_body=re.sub(r'##\{"html":"(.*?)"\}##',lambda x: html.unescape(x.group(1)),post_body,flags=re.DOTALL) + if 'Gmeek-html' in post_body: + pattern = r'Gmeek-html>(.*?)' + post_body=re.sub(pattern, r'\1', post_body) + +Gmeek-html postBase["postTitle"]=issue["postTitle"] postBase["postUrl"]=self.blogBase["homeUrl"]+"/"+issue["postUrl"]