Closed idbrii closed 4 months ago
This is the the same thing that git show -s --format=%s
does, correct? Probably not going to get fixed until that buffer gets redone.
Yup. git show -s --format=%s
does dump all the text on one line in commits lacking a blank line.
I see. It's due to the massive format in this line setting up a b:fugitive_type==commit
buffer:
https://github.com/tpope/vim-fugitive/blob/d0c1a437536778bcc8174b7cb2ffdf98f611e6fe/autoload/fugitive.vim#L3188
I use git-svn on a project that don't follow good commit message formatting. We frequently have commit messages that are mostly nicely formatted -- except for the "one blank line" rule. Git generally handles this fine, but fugitive does not.
:Gedit HEAD
(or navigating:G blame
and other commands that view a commit) will put the entire commit message on one line if it doesn't have a blank line after the first line.git log --online
also dumps it on one line.:G show HEAD
displays with expected newlines -- probably because it includes text from git verbatim?Example commit message:
Looks similar with
:G show HEAD
(but indented). However,:Gedit HEAD
results in one massive line:Tested on fugitive latest: d0c1a437536778bcc8174b7cb2ffdf98f611e6fe. Used gvim on Win10 and vim on Ubuntu 22.04.4 LTS (WSL).
Minimal vimrc: