summaryrefslogtreecommitdiff
path: root/plugin/hackernews.vim
diff options
context:
space:
mode:
authorryanss2015-03-30 13:52:37 -0400
committerryanss2015-03-30 13:52:37 -0400
commitb515dc0565b4435936c30105dc53701d2da9bd6c (patch)
treec04329066c1c26fe9b4993b661fea8d5bb44fdef /plugin/hackernews.vim
parentae9946f5b8f6d1c8113a77f78f150198e28d2574 (diff)
downloadvim-hn-b515dc0565b4435936c30105dc53701d2da9bd6c.tar.gz
Fix syntax highlighting issues
Diffstat (limited to 'plugin/hackernews.vim')
-rw-r--r--plugin/hackernews.vim3
1 files changed, 3 insertions, 0 deletions
diff --git a/plugin/hackernews.vim b/plugin/hackernews.vim
index bc786b4..6e818ab 100644
--- a/plugin/hackernews.vim
+++ b/plugin/hackernews.vim
@@ -14,6 +14,9 @@ filetype plugin on
" Load ftplugin when opening .hackernews buffer
au! BufRead,BufNewFile *.hackernews set filetype=hackernews
+" Prevent syntax highlighting issues in long comment threads with code blocks
+au! BufEnter *.hackernews syntax sync fromstart
+
function! HackerNews(...)
if a:0 > 0
let available_lists = ['news', 'newest', 'ask', 'show', 'shownew',