gitattributes

Is it possible to have all "git diff" commands use the "Python diff", in all git projects?

When including the line *.py diff=python in a local .gitattributes file, git diff produces nice labels for the different diff hunks of Python files (with the name of the function where the lines changes are, etc.). Is is possible to ask git to use this diff mode for all Python files across all git projects? I tried to set a global ~...

How to determine files that are subjected to filter via gitattributes when filter is executed?

I have bunch of ruby scripts in a git repository and it seems to be really hard to enforce people to write properly indented code. I also have a small ruby script that formats to code to specific standard and now i would like to run that as a a filter script so that junk wont get committed into repository. echo "*.rb filter=rubyfilte...