On 29/09/15 12:05, Ihar Hrachyshka wrote:
On 25 Sep 2015, at 16:44, Ihar Hrachyshka <ihrac...@redhat.com> wrote:
Hi all,
releases are approaching, so it’s the right time to start some bike shedding on
the mailing list.
Recently I got pointed out several times [1][2] that I violate our commit message
requirement [3] for the message lines that says: "Subsequent lines should be
wrapped at 72 characters.”
I agree that very long commit message lines can be bad, f.e. if they are 200+
chars. But <= 79 chars?.. Don’t think so. Especially since we have 79 chars
limit for the code.
We had a check for the line lengths in openstack-dev/hacking before but it was
killed [4] as per openstack-dev@ discussion [5].
I believe commit message lines of <=80 chars are absolutely fine and should not
get -1 treatment. I propose to raise the limit for the guideline on wiki
accordingly.
Comments?
[1]: https://review.openstack.org/#/c/224728/6//COMMIT_MSG
[2]: https://review.openstack.org/#/c/227319/2//COMMIT_MSG
[3]:
https://wiki.openstack.org/wiki/GitCommitMessages#Summary_of_Git_commit_message_structure
[4]: https://review.openstack.org/#/c/142585/
[5]:
http://lists.openstack.org/pipermail/openstack-dev/2014-December/thread.html#52519
Ihar
Thanks everyone for replies.
Now I realize WHY we do it with 72 chars and not 80 chars (git log output). :)
I updated the wiki page with how to configure Vim to enforce the rule. I also
removed the notion of gating on commit messages because we have them removed
since recently.
Thanks Ihar! FWIW, vim has had built-in support for setting that width
since at least 7.2, and I suspect long before (for me it's in
/usr/share/vim/vim74/ftplugin/gitcommit.vim). AFAIK the only thing you
need in your .vimrc to take advantage is:
if has("autocmd")
filetype plugin indent on
endif " has("autocmd")
This is included in the example vimrc file that ships with vim, so I
think better advice for 99% of people would be to just install the
example vimrc file if they don't already have a ~/.vimrc. (There are
*lots* of other benefits too.) I've updated the wiki to reflect that, I
hope you don't mind :)
It'd be great if anyone who didn't have it set up already could try this
though, since it's been many, many years since it has not worked
automagically for me ;)
cheers,
Zane.
__________________________________________________________________________
OpenStack Development Mailing List (not for usage questions)
Unsubscribe: openstack-dev-requ...@lists.openstack.org?subject:unsubscribe
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev