diff options
Diffstat (limited to 'syntax/hackernews.vim')
| -rw-r--r-- | syntax/hackernews.vim | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/syntax/hackernews.vim b/syntax/hackernews.vim index bc249a2..a21d68b 100644 --- a/syntax/hackernews.vim +++ b/syntax/hackernews.vim @@ -18,11 +18,16 @@ syn match Ignore /\s\[[0-9]\{3,}\]$/ " Make sure `Ignore` highlight group is hidden " Some colorschemes do not hide the `Ignore` group (ex. Solarized) -if has('gui_running') - highlight Ignore guifg=bg -else - highlight Ignore ctermfg=bg -endif +" An exception will be raised here if ctermfg=NONE which is sometimes set +" when using a transparent terminal so we wrap these commands in try/catch +try + if has('gui_running') + highlight Ignore guifg=bg + else + highlight Ignore ctermfg=bg + endif +catch +endtry " Remove emphesis from all components of main page item except title syn match Comment /^\s*[0-9]\{1,2}\.\s/ |
