Mercurial > hg
view mcabber/contrib/vim/mcabber_log-ftdetect.vim @ 2289:a63814f2e4c8
contrib/vim: Support reloading filetype detection
Merge Gentoo patch. Thanks to Amadeusz Żołnowski and Wolfram Schlich.
author | Mikael Berthe <mikael@lilotux.net> |
---|---|
date | Wed, 21 Dec 2016 20:30:56 +0100 |
parents | c5b2789443c3 |
children |
line wrap: on
line source
" " Save this file in your ~/.vim/ftdetect/ folder function! MCabber_log_ftdetect() if getline(1) =~ '^\u. \d\{8}T\d\d:\d\d:\d\dZ \d\{3} ' setlocal filetype=mcabber_log endif endfunction autocmd BufRead */*mcabber/histo/* call MCabber_log_ftdetect()