Repository : ssh://git@open-mesh.org/batctl
On branch : master
commit eb819b8be1157f08a3e2b91ad303d0ee6caa64af Author: Jean Delvare jdelvare@suse.de Date: Tue Feb 21 10:06:40 2017 +0100
batctl: set git diff driver for C source code files
Git can be told to apply language-specific rules when generating diffs. Enable this for C source code files (*.c and *.h) so that function names are printed right. Specifically, doing so prevents "git diff" from mistakenly considering unindented goto labels as function names.
Signed-off-by: Jean Delvare jdelvare@suse.de [sven@narfation.org: Ported patch from linux.git] Signed-off-by: Sven Eckelmann sven@narfation.org
eb819b8be1157f08a3e2b91ad303d0ee6caa64af .gitattributes | 2 ++ 1 file changed, 2 insertions(+)
diff --git a/.gitattributes b/.gitattributes index eeef3e0..1d2a7e9 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1,2 +1,4 @@ /.gitignore export-ignore /.gitattributes export-ignore +*.c diff=cpp +*.h diff=cpp