- Where Developers Learn, Share, & Build Careers


I want to modify updatetime for vim for files with specific extensions. I have tried to accomplish this by adding the following code to my ~ / .vimrc :

  Autocommed bufferide, buffanwayfile * .t set uptaid time = 60000 < / Code>  

This does not seem to work when I open a file with the .t extension and : set ut? I see the default updatetime = 4000 .

'updatetime' setting is a global setting, it means different Do not assume why you want a different price for different buffers?

You can work with AutoComed on it, as you have tried, however, BufRead, BufNewFile event will only happen if a buffer is loaded; This setting will not update as you switch buffers, the correct method is to define two autocmds on BufEnter ; To reset a normal one setting, and (after that, it has been executed after the first time!) That matches your file pattern and organizes the settings:

  Autocmd BufEnter * set updatetime = 4000 Autocomedged buffent * .tet set uptime = 60000    

Comments

Popular posts from this blog

java - NullPointerException for a 2d Array -

python - Assemble mpeg file unable to play in mediaplayer -

c# - NameSpace Manager or XsltContent to parse aspx page -