diff options
| author | ryanss | 2015-03-01 22:22:28 -0500 |
|---|---|---|
| committer | ryanss | 2015-03-01 22:22:28 -0500 |
| commit | 01c80666fcb799b1889537ea172114be3b08fc57 (patch) | |
| tree | a889db6050efe1f7eee394d9ef48f0af85ffcb28 /ftplugin/hackernews.py | |
| parent | 8d1b3be4be06c4304bc19c93d99828faa2f3eaff (diff) | |
| download | vim-hn-01c80666fcb799b1889537ea172114be3b08fc57.tar.gz | |
Replace <i>italic</i> tags with _italic_ underscores
Diffstat (limited to 'ftplugin/hackernews.py')
| -rw-r--r-- | ftplugin/hackernews.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/ftplugin/hackernews.py b/ftplugin/hackernews.py index 26cfa62..1fc205c 100644 --- a/ftplugin/hackernews.py +++ b/ftplugin/hackernews.py @@ -275,6 +275,7 @@ def print_content(content): if not p: continue p = html.unescape(p) + p = p.replace("<i>", "_").replace("</i>", "_") # Convert <a href="http://url/">Text</a> tags # to markdown equivalent: (Text)[http://url/] @@ -311,6 +312,7 @@ def print_comments(comments, level=0): if not p: continue p = html.unescape(p) + p = p.replace("<i>", "_").replace("</i>", "_") # Extract code block before textwrap to conserve whitespace code = None |
