D | make_cdd.py | 171 def elim_para_whitespace(html): argument 172 …ompile(r"(<p[^>]*>)\s*\n\s*(<a[^>]*>)\n([^<]*)\n\s*(</a>)\n\s*(</p>)", re.M),r"\1\2\3\4\5\n", html) 176 def elim_space_before_punc(html): argument 177 new_html = re.sub(re.compile(r"</a>\s+([.,;:])", re.M),r"</a>\1", html) 200 html = soup.prettify(formatter='html') 209 html = soup.prettify(formatter='html') 212 html = re.sub(re.compile(r'ANDROID_VERSION'), ANDROID_VERSION, html) 213 html = re.sub(re.compile(r'CURRENT_BRANCH'), CURRENT_BRANCH, html) 219 (document, errors) = tidylib.tidy_document(html, options={'doctype': 'omit'}) 223 html = elim_space_before_punc(html)
|