Vim inoremap for specific filetypes

后端 未结 5 2092
孤独总比滥情好
孤独总比滥情好 2020-11-29 11:38

I\'ve added some simple inoremap commands to my .vimrc to help with parens and brackets completion, but I only want them to apply to php files.

5条回答
  •  攒了一身酷
    2020-11-29 12:09

    Add them to the ftplugin file in the after directory:

    ~/.vim/after/ftplugin/php.vim
    

    More info in this answer.

    Edit: This file, and maybe even the directory, will not be there by default. You may have to make it if you don't see it there.

提交回复
热议问题