Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 559920

Summary: dev-vcs/git-2.4.6: default commit hook whitespace check chokes on valid single blank line at EOF
Product: Gentoo Linux Reporter: Raymond Jennings <shentino>
Component: Current packagesAssignee: Gentoo Linux bug wranglers <bug-wranglers>
Status: RESOLVED INVALID    
Severity: normal    
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---

Description Raymond Jennings 2015-09-08 01:35:36 UTC
It's actually quite proper for a source code file to have a single blank line at the end.  It's to prevent the file from having a line that does not end in a newline.

However, the default commit hook doesn't check to see if a blank line at the end is the only one or not.

Reproducible: Always
Comment 1 Raymond Jennings 2015-09-08 05:04:02 UTC
Just took a look at the file "the hard way" by using mcedit in a console.

The file is properly terminated by a newline, but gedit doesn't show that.

New bug is being filed against gedit.