On Mon, 23 Jul 2018, Segher Boessenkool wrote: > For example for .md files you can use > > [diff "md"] > xfuncname = "^\\(define.*$" > > in your local clone's .git/config > > and > > *.md diff=md > > in .gitattributes (somewhere in the source tree).
Not necessarily in the source tree: individual users can put that into their $XDG_CONFIG_HOME/git/attributes or $HOME/.config/git/attributes. Likewise the previous snippet can go into $HOME/.gitconfig rather than each individual cloned tree. (the point is, there's no need to split this quality-of-life change between the repository and the user's setup - it can be done once by a user and will work for all future checkouts) Alexander