textwidth not set for git commit message in vim #91

kgybels opened this Issue Jan 12, 2013 · 4 comments

3 participants


When enabling syntax from the user's vimrc the textwidth no longer gets set for the git commit message.

Steps to reproduce:
1. rm ~/.vimrc
2. git commit
3. textwidth is correctly set to 74
4. echo syntax on > ~/.vimrc
5. git commit
6. textwidth no longer set to 74 but to 0

MSysGit - the development behind Git for Windows member

I can reproduce this issue, though I have some questions:

1) Why would you want to set syntax on as that's already done in C:\Program Files (x86)\Git\share\vim\vimrc?
2) I'm not very familiar with configuring vim, but according to this page syntax on overrules your settings with the defaults. So it's expected that our customization to the textwidth is gone, or?


1) Because this file is also used by the vim from vim.org, which I use. Without syntax on in my config file that command line vim will not use syntax highlighting.
2) You can also reproduce the problem with "syntax enable" instead of "syntax on" if you prefer that. I think the difference is not really important when done in your configuration file.

MSysGit - the development behind Git for Windows member

Ok, so you're probably in the best position to fix this (I myself have to experience with configuring vim at all). A pull request with a fix would be appreciated.

MSysGit - the development behind Git for Windows member

@dscho dscho closed this Apr 15, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment