Server : Apache System : Linux server1.cgrithy.com 3.10.0-1160.95.1.el7.x86_64 #1 SMP Mon Jul 24 13:59:37 UTC 2023 x86_64 User : nobody ( 99) PHP Version : 8.1.23 Disable Function : NONE Directory : /usr/share/doc/git-1.8.3.1/contrib/vim/ |
Syntax highlighting for git commit messages, config files, etc. is included with the vim distribution as of vim 7.2, and should work automatically. If you have an older version of vim, you can get the latest syntax files from the vim project: http://ftp.vim.org/pub/vim/runtime/syntax/git.vim http://ftp.vim.org/pub/vim/runtime/syntax/gitcommit.vim http://ftp.vim.org/pub/vim/runtime/syntax/gitconfig.vim http://ftp.vim.org/pub/vim/runtime/syntax/gitrebase.vim http://ftp.vim.org/pub/vim/runtime/syntax/gitsendemail.vim These files are also available via FTP at the same location. To install: 1. Copy these files to vim's syntax directory $HOME/.vim/syntax 2. To auto-detect the editing of various git-related filetypes: $ curl http://ftp.vim.org/pub/vim/runtime/filetype.vim | sed -ne '/^" Git$/, /^$/ p' >>$HOME/.vim/filetype.vim