diff options
author | Teddy Wing | 2019-06-05 20:39:33 +0200 |
---|---|---|
committer | Teddy Wing | 2019-06-05 20:39:33 +0200 |
commit | d5efa59a2aab4d07e6ad16b510bee3077db64bf4 (patch) | |
tree | 434652c6196258e8194542734808cc7a70545926 /ftplugin/gitcommit.vim | |
parent | c0a8a7cee99894fd24144cf44f3498e6b50b9958 (diff) | |
download | dotvim-d5efa59a2aab4d07e6ad16b510bee3077db64bf4.tar.bz2 |
ftplugin/gitcommit.vim: Turn on 'formatoptions' `n`
This formats numbered lists so that they wrap to the beginning of the
text, instead of being flush with the number.
Before:
1. A list that goes beyond the text width and
wraps to the number.
After:
1. A list that goes beyond the text width and
wraps to the text.
Thanks to this blog post from Edward Yang for prompting me to read the
|fo-table| help again more closely:
http://blog.ezyang.com/2010/03/vim-textwidth/
Diffstat (limited to 'ftplugin/gitcommit.vim')
-rw-r--r-- | ftplugin/gitcommit.vim | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/ftplugin/gitcommit.vim b/ftplugin/gitcommit.vim index 05cf30e..44a2e3f 100644 --- a/ftplugin/gitcommit.vim +++ b/ftplugin/gitcommit.vim @@ -15,3 +15,7 @@ setlocal spell " Make bulleted lists with '*' not start wrapped lines with '*' setlocal comments-=mb:* comments+=fb:* + + +" Proper line wrapping for numbered lists +setlocal formatoptions+=n |