dot/gitconfig.in: Run `diff-highlight' from the path, if it's there.
[profile] / dot / gitconfig.in
index ebd17bf..0ec6ed2 100644 (file)
@@ -3,35 +3,63 @@
 
 [core]
        filemode = true
-       excludesfile = @gitignore@
+       excludesfile = @profile@/git/gitignore
+       attributesfile = @profile@/git/attributes
+       whitespace = trailing-space,space-before-tab,indent-with-non-tab
+
+[advice]
+       ignoredHook = false
 
 [user]
        name = Mark Wooding
        email = mdw@distorted.org.uk
        signingkey = @releasekey@
 
+[annex]
+       sshcaching = false
+
 [merge]
        summary = true
        tool = emerge
+       conflictStyle = diff3
 
 [mergetool "emerge"]
        path = emerge-hack
 
 [diff]
        renames = copies
+       renameLimit = 1024
+       wordRegex = [[:alnum:]]+|[^[:space:][:alnum:]]
 
 [diff "lisp"]
-       xfuncname = "^\\s*\\(def.*$"
+       xfuncname = "^((\\(|\\s*\\(def).*$)"
+
+[log]
+       date = rfc
+       decorate = true
+       follow = true
+       mailmap = true
+
+[rebase]
+       autosquash = true
+
+[pull]
+       rebase = false
+
+[push]
+       default = upstream
+       followTags = true
 
 [format]
        headers = "Organization: Straylight/Edgeware\n"
+       from = Mark Wooding <@email@>
+       coverletter = auto
+       thread = shallow
+       signature = "[mdw]"
+       outputdirectory = p/
 
 [color]
-       diff = auto
-       status = auto
-       branch = auto
-       interactive = auto
-       grep = auto
+       ui = auto
 
 [color "diff"]
        plain = normal
        whitespace = reverse red
 
 [color "interactive"]
-        prompt = bold yellow
-        header = bold
-        help = green
-        error = bold red
+       prompt = bold yellow
+       header = bold
+       help = green
+       error = bold red
 
 [color "status"]
        header = bold
        local = normal
        remote = cyan
 
-[color "grep"]
-       external = --color=always
+[column]
+       ui = auto column dense
+
+[pager]
+       diff = "if type >/dev/null 2>&1 diff-highlight; then diff-highlight; else cat; fi | mdw-pager"
+       log = "if type >/dev/null 2>&1 diff-highlight; then diff-highlight; else cat; fi | mdw-pager"
+       show = "if type >/dev/null 2>&1 diff-highlight; then diff-highlight; else cat; fi | mdw-pager"
 
 [alias]
+       do = "!sh -e -c ' \
+               quiet=; \
+               case $#,$1 in 0, | *,*,*) ;; *,-q) quiet=--quiet; shift ;; esac; \
+               case $quiet in ?*) ;; *) echo \"Entering toplevel\" ;; esac; \
+               (name=\"<toplevel>\"; path=.; toplevel=$(pwd); \
+                sha1=$(git rev-parse HEAD); \
+                set +e; case $# in 1) eval \"$1\" ;; *) \"$@\" ;; esac); \
+               exec git submodule $quiet foreach --recursive \"$@\"' do"
        egrep = "grep -E"
-       patch = "format-patch -o p -s"
+       graph = "log --pretty=oneline --abbrev-commit --graph"
        release = !"sh -e -c ' \
                [ $# -gt 0 ] || { \
                  echo >&2 \"usage: git release TAG [OPTS]\"; \
                  exit 1; \
                }; \
                git tag -as -m \"Release $1.\" \"$@\"' release"
+       catchup = !"perl -e ' \
+               use autodie qw(:all); \
+               if (@ARGV < 2) { \
+                 print STDERR \"git catchup REMOTE REF ...\n\"; \
+                 exit 2; \
+               } \
+               @c = (); $m = shift @ARGV; \
+               for my $r (@ARGV) { \
+                 my ($p, $r) = $r =~ /^([+]*)(.*)$/; \
+                 push @c, \"$p$m/$r:$r\"; \
+               } \
+               exec \"git\", \"push\", \".\", @c'"
        amend = !"env EDITOR=true VISUAL=true git commit --amend -a"
        spaces = !"sh -e -c 'git ls-files -z \"$@\"| \
                xargs -0r space -cv' spaces"
-       mailto = "send-email \
-                       --quiet \
-                       --no-chain-reply-to \
-                       --no-signed-off-by-cc \
-                       --to"
        files = "ls-files --exclude-standard"
        unstg = !"sh -e -c ' \
                : ${GIT_DIR=$(git rev-parse --git-dir)}; \
 
 [rerere]
        enabled = yes
+       autoupdate = yes
 
 [stgit]
        autoresolved = yes
        mdw = mdw@distorted.org.uk
 
 [sendemail]
+       from = Mark Wooding <mdw@distorted.org.uk>
+       aliasesfile = @profile@/dot/mailrc
+       aliasfiletype = mailrc
        chainreplyto = no
-       signedoffcc = yes
+       thread = no
+       signedoffbycc = yes
+       suppresscc = self
+
+[mailinfo]
+       scissors = true
 
 [gui]
        fontui = -family Sans -size 10
-       fontdiff = -family MiscFixed6x13 -size 10
+       fontdiff = -family Fixed -size 13
+
+[http]
+       cookiefile = @home@/.gitcookies